B
Brian Barnes
I am trying to create a template code behind file for a website which all
pages should be inherited from. This base class however, when I try to view
the aspx page in Visual studio .NET (2002), it gives me the error:
The file failed to load in the web form designer. Plese correct the
following error, then load it again: An exception occurred while trying to
create an instance of GManWebSync.templates.WebBase (the base class). The
exception was "Object reference not set to an instance of an object."
Despite the fact that the file displays as expected in the web browser. I am
able to view the html code of the page so is more of a nusance. I have moved
the header html tag to be written from the template, however I have not
taken out the header section of all the pages yet (but this problem occurs
with all pages). I am sure that all varibles are initialised before they are
used (assuming "titlebar = CType(LoadControl(Request.ApplicationPath &
"/Components/comtop.ascx"), comTop)" initalises titlebar) as it compiles and
functions as expected
The page structure is going to be a title bar (initialised with the above
line) and then a table with 2 columns with a menu in the left column
(currently not shown (as I am having difficulties including it), but
designed as a component) and a maintaince side in the right (in which my
manager wants to have some changes reflected in the menu e.g. changing a
users name will change the link in the left menu) . The template is designed
to have the code to write the header information, include the title bar (it
is a basic component), write the table, include the menu, write the
maintaince page (which inherits the template page) and close the table and
body.
Any suggestions as to what I should look at closer
pages should be inherited from. This base class however, when I try to view
the aspx page in Visual studio .NET (2002), it gives me the error:
The file failed to load in the web form designer. Plese correct the
following error, then load it again: An exception occurred while trying to
create an instance of GManWebSync.templates.WebBase (the base class). The
exception was "Object reference not set to an instance of an object."
Despite the fact that the file displays as expected in the web browser. I am
able to view the html code of the page so is more of a nusance. I have moved
the header html tag to be written from the template, however I have not
taken out the header section of all the pages yet (but this problem occurs
with all pages). I am sure that all varibles are initialised before they are
used (assuming "titlebar = CType(LoadControl(Request.ApplicationPath &
"/Components/comtop.ascx"), comTop)" initalises titlebar) as it compiles and
functions as expected
The page structure is going to be a title bar (initialised with the above
line) and then a table with 2 columns with a menu in the left column
(currently not shown (as I am having difficulties including it), but
designed as a component) and a maintaince side in the right (in which my
manager wants to have some changes reflected in the menu e.g. changing a
users name will change the link in the left menu) . The template is designed
to have the code to write the header information, include the title bar (it
is a basic component), write the table, include the menu, write the
maintaince page (which inherits the template page) and close the table and
body.
Any suggestions as to what I should look at closer