Best Place to Put Class Accessible to All "Folders"

  • Thread starter Johnny Meredith
  • Start date
J

Johnny Meredith

Warning: Tenderfoot

I'm playing around with ASP.Net 2.0 b2. The web app I've created has a
default, login, recovery, etc. pages in the root and two folders
accessible to authenticated users only. I have a simple class that
needs to be accessible to the two subfolders mentioned above. I placed
this class in App_Code and declared it Friend/Internal. However, I
can't access it in the two subfolders unless it's declared Public.

I thought Friend/Internal meant that I could access the class from
anywhere in this project, but not from outside it. Should I be using
App_GlobalResources, App_LocalResources folders (or something else), or
am I just wrong regarding Friend/Internal classes?

Thanks,
Johnny
 
S

Scott Allen

Hi Johnny:
I thought Friend/Internal meant that I could access the class from
anywhere in this project, but not from outside it. Should I be using
App_GlobalResources, App_LocalResources folders (or something else), or
am I just wrong regarding Friend/Internal classes?

Internal means you can access the class from inside the same assembly.
Unfortunately stuff in App_Code goes into one assembly and ASPX
webforms code goes into a second.
 

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

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,534
Members
45,007
Latest member
OrderFitnessKetoCapsules

Latest Threads

Top