using includes causes error

T

thersitz

Hi,

I am using include statements in my asp.net files as such:

<!--#include file="sideBarPartTwo.aspx" -->

doing so places an error in my design view of VStudio 2005 -- and then does
not allow me to see the page in design view -- it merely shows an "Error
Creating Control" box with the following error message,

"Content1:eek:bject reference not set to an instance of the object"

content1 refers to my <asp:Content ID="Content1"
ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server"> tag

The page views ok -- the includes show properly -- but it basically prevents
me from being able to work in design view. Any ideas why this occurs? thanks
 
J

John Saunders

thersitz said:
Hi,

I am using include statements in my asp.net files as such:

<!--#include file="sideBarPartTwo.aspx" -->

I recommend against using Server Side Includes. They're a holdover from
classig ASP. I would suggest using User Controls instead. It's a
straghtforward conversion.

John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,576
Members
45,054
Latest member
LucyCarper

Latest Threads

Top