Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / October 2005

Tip: Looking for answers? Try searching our database.

Page namespaces in .NET 2.0

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Michael Carr - 31 Oct 2005 06:10 GMT
I am working on a web application project that I migrated from .NET 1.1. In
this application, I sometimes expose static constant strings from my
inherited page class that hold, for example, some human readable text that I
want to display in a second page that will display the text and allow the
user to link to the first one. In .NET 2.0, it seems that I cannot use this
technique because other pages do not appear within my namespace any more...
so far, only classes I create in App_Data seem to be accessible from within
my page codebehind. Is this the case--that I can no longer access a page
class from within another page class? Also, this also seems to be the case
with User Controls... how useful are User Controls if I cannot access the
class from the page class that contains them?

   Not quite getting it,
   Michael Carr
Michael Carr - 31 Oct 2005 06:19 GMT
I just discovered the @Reference directive and it seems to be helping...
except circular reference problems are going to drive me nuts now. So
@Reference is a basically a return to old-fashioned include files with their
all their circular reference problems, eh? Looks like I'm going to be up
late tonight...

   Michael Carr

> In .NET 2.0, it seems that I cannot use this technique because other pages
> do not appear within my namespace any more...
Juan T. Llibre - 31 Oct 2005 13:39 GMT
Check these out :

http://odetocode.com/Blogs/scott/archive/2005/09/12/2186.aspx

http://west-wind.com/weblog/posts/3016.aspx

btw, you meant the App_Code directory, not App_Data.

Juan T. Llibre, ASP.NET MVP
ASP.NET FAQ : http://asp.net.do/faq/
Foros de ASP.NET en Español : http://asp.net.do/foros/
======================================
>I am working on a web application project that I migrated from .NET 1.1. In this
>application, I sometimes expose static constant strings from my inherited page class that
[quoted text clipped - 9 lines]
>    Not quite getting it,
>    Michael Carr

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.