[MonoDevelop] ASP.NET 2.0 -Master Page
Paulo Aboim Pinto
esqueleto at tusofona.com
Tue May 22 05:50:18 EDT 2007
I only make your change and get this error. I don't have partial classes.
Server Error in '/' Application
Compilation Error
Description: Error compiling a resource required to service this
request. Review your source file and modify it to fix this error.
Error message:
/tmp/esqueleto-temp-aspnet-0/3ae7dee8/12729953.0.cs(14,26) : error
CS0260: Missing partial modifier on declaration of type
`MasterPageExample.chezTolib'. Another partial declaration of this type
exists
File name:
/home/esqueleto/Projects/MasterPageExample/MasterPageExample/chezTolib.master
Source File: /tmp/esqueleto-temp-aspnet-0/3ae7dee8/12729953.0.cs
Line 1: //
------------------------------------------------------------------------------
Line 2: // <autogenerated>
Line 3: // This code was generated by a tool.
Line 4: // Mono Runtime Version: 2.0.50727.42
Line 5: //
Line 6: // Changes to this file may cause incorrect behavior and
will be lost if
Line 7: // the code is regenerated.
Line 8: // </autogenerated>
Line 9: //
------------------------------------------------------------------------------
Line 10:
Line 11: namespace MasterPageExample {
Line 12:
Line 13:
Line 14: public partial class chezTolib {
Line 15:
Line 16: protected System.Web.UI.HtmlControls.HtmlHead _bctrl_4;
Line 17:
Line 18: protected System.Web.UI.HtmlControls.HtmlTitle _bctrl_5;
Line 19:
Line 20: protected System.Web.UI.HtmlControls.HtmlForm form1;
Line 21:
Line 22: protected System.Web.UI.WebControls.ContentPlaceHolder
ContentPlaceHolder1;
Line 23:
Line 24: protected System.Web.HttpApplication ApplicationInstance {
Line 25: get {
Line 26: return
((System.Web.HttpApplication)(this.Context.ApplicationInstance));
Line 27: }
Line 28: }
Line 29: }
Line 30: }
Line 31: namespace ASP {
Line 32: using System;
Line 33: using System.Collections;
Line 34: using System.Collections.Specialized;
Line 35: using System.Configuration;
Line 36: using System.Text;
Line 37: using System.Text.RegularExpressions;
Line 38: using System.Web;
Line 39: using System.Web.Caching;
Line 40: using System.Web.SessionState;
Line 41: using System.Web.Security;
Line 42: using System.Web.Profile;
Line 43: using System.Web.UI;
Line 44: using System.Web.UI.WebControls;
Line 45: using System.Web.UI.HtmlControls;
Line 46:
Line 47:
Line 48: public class cheztolib_master :
global::MasterPageExample.chezTolib {
Line 49:
Line 50: private static bool __initialized = false;
Line 51:
Line 52: private static int __autoHandlers;
Line 53:
Line 54: private System.Web.UI.ITemplate
__Template_ContentPlaceHolder1;
Line 55:
Line 56: public cheztolib_master() {
Line 57:
((System.Web.UI.MasterPage)(this)).AppRelativeVirtualPath =
"~/chezTolib.master";
Line 58: if ((cheztolib_master.__initialized == false)) {
Line 59: cheztolib_master.__initialized = true;
Line 60: }
Line 61: }
Line 62:
Line 63: [System.Obsolete()]
Line 64: protected override int AutoHandlers {
Line 65: get {
Line 66: return ASP.cheztolib_master.__autoHandlers;
Line 67: }
Line 68: set {
Line 69: ASP.cheztolib_master.__autoHandlers = value;
Line 70: }
Line 71: }
Line 72:
Line 73: public override string TemplateSourceDirectory {
Line 74: get {
Line 75: return "/";
Line 76: }
Line 77: }
Line 78:
Line 79: private void __BuildControlTree(cheztolib_master __ctrl) {
Line 80: System.Web.UI.IParserAccessor __parser =
((System.Web.UI.IParserAccessor)(__ctrl));
Line 81: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML
1.0 Transitional//EN\"
\"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">\n\n<html
xmlns=\"http://www.w3.org/1999/xhtml\" >\n"));
Line 82: this.__BuildControl__bctrl_4();
Line 83: __parser.AddParsedSubObject(this._bctrl_4);
Line 84: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("\n<body>\n "));
Line 85: this.__BuildControl_form1();
Line 86: __parser.AddParsedSubObject(this.form1);
Line 87: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("\n</body>\n</html>"));
Line 88: }
Line 89:
Line 90: private System.Web.UI.Control __BuildControl__bctrl_4() {
Line 91: System.Web.UI.HtmlControls.HtmlHead __ctrl;
Line 92: __ctrl = new
System.Web.UI.HtmlControls.HtmlHead("head");
Line 93: this._bctrl_4 = __ctrl;
Line 94: this.__BuildControl__bctrl_5();
Line 95: System.Web.UI.IParserAccessor __parser =
((System.Web.UI.IParserAccessor)(__ctrl));
Line 96: __parser.AddParsedSubObject(this._bctrl_5);
Line 97: return __ctrl;
Line 98: }
Line 99:
Line 100: private System.Web.UI.Control __BuildControl__bctrl_5() {
Line 101: System.Web.UI.HtmlControls.HtmlTitle __ctrl;
Line 102: __ctrl = new System.Web.UI.HtmlControls.HtmlTitle();
Line 103: this._bctrl_5 = __ctrl;
Line 104: System.Web.UI.IParserAccessor __parser =
((System.Web.UI.IParserAccessor)(__ctrl));
Line 105: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("Untitled Page"));
Line 106: return __ctrl;
Line 107: }
Line 108:
Line 109: private System.Web.UI.Control __BuildControl_form1() {
Line 110: System.Web.UI.HtmlControls.HtmlForm __ctrl;
Line 111: __ctrl = new System.Web.UI.HtmlControls.HtmlForm();
Line 112: this.form1 = __ctrl;
Line 113: __ctrl.ID = "form1";
Line 114: System.Web.UI.IParserAccessor __parser =
((System.Web.UI.IParserAccessor)(__ctrl));
Line 115: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("\n <div>\n "));
Line 116: this.__BuildControl_ContentPlaceHolder1();
Line 117: __parser.AddParsedSubObject(this.ContentPlaceHolder1);
Line 118: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("\n </div>\n "));
Line 119: return __ctrl;
Line 120: }
Line 121:
Line 122: private System.Web.UI.Control
__BuildControl_ContentPlaceHolder1() {
Line 123: System.Web.UI.WebControls.ContentPlaceHolder __ctrl;
Line 124: __ctrl = new
System.Web.UI.WebControls.ContentPlaceHolder();
Line 125: this.ContentPlaceHolder1 = __ctrl;
Line 126: this.ContentPlaceHolders.Add(__ctrl);
Line 127: if ((this.ContentTemplates != null)) {
Line 128: this.__Template_ContentPlaceHolder1 =
((System.Web.UI.ITemplate)(this.ContentTemplates["ContentPlaceHolder1"]));
Line 129: }
Line 130: if ((this.__Template_ContentPlaceHolder1 != null)) {
Line 131:
this.__Template_ContentPlaceHolder1.InstantiateIn(__ctrl);
Line 132: }
Line 133: else {
Line 134: System.Web.UI.IParserAccessor __parser =
((System.Web.UI.IParserAccessor)(__ctrl));
Line 135: __parser.AddParsedSubObject(new
System.Web.UI.LiteralControl("\n "));
Line 136: }
Line 137: __ctrl.TemplateControl = this;
Line 138: __ctrl.ID = "ContentPlaceHolder1";
Line 139: return __ctrl;
Line 140: }
Line 141:
Line 142: protected override void FrameworkInitialize() {
Line 143: base.FrameworkInitialize();
Line 144: this.__BuildControlTree(this);
Line 145: }
Line 146: }
Line 147: }
5/22/2007 9:49:14 AM
Marek Habersack wrote:
> On Tue, 22 May 2007 00:21:31 +0100, Paulo Aboim Pinto <esqueleto at tusofona.com>
> scribbled:
>
>> Master Page Code Behind:
>>
>> using System;
>> using System.Configuration;
>> using System.Collections;
>> using System.Web;
>> using System.Web.Security;
>> using System.Web.UI;
>> using System.Web.UI.WebControls;
>> using System.Web.UI.WebControls.WebParts;
>> using System.Web.UI.HtmlControls;
>>
>> namespace MasterPageExample
>> {
>> public class chezTolib : System.Web.UI.MasterPage
>> {
>> }
>> }
>>
>>
>> Default.ASPX Code Behind
>>
>> using System;
>> using System.Web;
>> using System.Web.UI;
>>
>> namespace MasterPageExample
>> {
>> public class Default : Page
>> {
>> }
>> }
> If this is your codebehind, then your .master and .aspx 'inherits' attributes
> should look, respectively, like this:
>
> Inherits="MasterPageExample.chezToLib"
> Inherits="MasterPageExample.Default"
>
> best regards,
>
> marek
More information about the Monodevelop-list
mailing list