[Mono-bugs] [Bug 80129][Wis] Changed - 2.0/SVN: using masterpage class from within page code is not possible

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Fri Jan 19 19:35:30 EST 2007


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by grendello at gmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=80129

--- shadow/80129	2006-12-24 07:04:46.000000000 -0500
+++ shadow/80129.tmp.2514	2007-01-19 19:35:30.000000000 -0500
@@ -1,13 +1,13 @@
 Bug#: 80129
 Product: Mono: Class Libraries
 Version: 1.2
 OS: unknown
 OS Details: 
-Status: NEW   
-Resolution: 
+Status: RESOLVED   
+Resolution: NOTABUG
 Severity: Unknown
 Priority: Wishlist
 Component: Sys.Web
 AssignedTo: grendello at gmail.com                            
 ReportedBy: ck at carlo-kok.com               
 QAContact: mono-bugs at ximian.com
@@ -65,6 +65,43 @@
 ------- Additional Comments From ck at carlo-kok.com  2006-12-24 07:04 -------
 Thanks, seems my testcase was slightly wrong however it seems that
 without the <%@ MasterType VirtualPath="~/MyMasterPage.master" %> it's
 unable to access that type. On .NET 2.0 it works without that
 directive, although now I know what the problem is, the issue is
 solved for it.
+
+------- Additional Comments From grendello at gmail.com  2007-01-19 19:35 -------
+On latest MS.NET 2.0 runtime, I get the following error:
+
+--------------------------
+Source Error: 
+
+Line 13:     protected void Page_Load(object sender, EventArgs e)
+Line 14:     {
+Line 15:       (Master as MyMasterPage).Test();
+Line 16:       testclass tc = new testclass();
+Line 17:     }
+
+
+Source File: c:\Inetpub\wwwroot\Default.aspx.cs    Line: 15 
+
+Stack Trace: 
+
+[NullReferenceException: Object reference not set to an instance of 
+an object.]
+   _Default.Page_Load(Object sender, EventArgs e) in 
+c:\Inetpub\wwwroot\Default.aspx.cs:15
+   System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, 
+Object o, Object t, EventArgs e) +13
+   System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object 
+sender, EventArgs e) +45
+   System.Web.UI.Control.OnLoad(EventArgs e) +80
+   System.Web.UI.Control.LoadRecursive() +49
+   System.Web.UI.Page.ProcessRequestMain(Boolean 
+includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) 
++3743
+
+--------------
+
+So it seems that Mono behavior is correct. I'm closing the bug, if 
+you can confirm that MS.NET 2.0 does indeed work in this case, feel 
+free to reopen it.


More information about the mono-bugs mailing list