Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie

.Net Namespaces

Options
  • 14-03-2005 4:58pm
    #1
    Moderators, Society & Culture Moderators Posts: 9,689 Mod ✭✭✭✭


    I'm trying to get a handle on .net namespaces and failing miserably so any help or pointers would be appreciated. As far as I can tell, they work on a similar principal to java packages which I can manage easily enough, maybe I'm just missing something simple.

    Basically I have a solution called ArcosNET, within this I have 2 projects (each in their own sub-directories off ArcosNET) ArcosNET.BO and ArcosNET.DO for business and data objects. I've been trying to get one to 'see' the other using the imports command but each can only 'see' it's own namespace. I've tried setting the namespaces using the properties of each individual project, using namespace blocks in the class files and various combinations of both to no success. Anybody know how this should be layed out ?


Comments

  • Registered Users Posts: 640 ✭✭✭Kernel32


    stevenmu wrote:
    I'm trying to get a handle on .net namespaces and failing miserably so any help or pointers would be appreciated. As far as I can tell, they work on a similar principal to java packages which I can manage easily enough, maybe I'm just missing something simple.

    Basically I have a solution called ArcosNET, within this I have 2 projects (each in their own sub-directories off ArcosNET) ArcosNET.BO and ArcosNET.DO for business and data objects. I've been trying to get one to 'see' the other using the imports command but each can only 'see' it's own namespace. I've tried setting the namespaces using the properties of each individual project, using namespace blocks in the class files and various combinations of both to no success. Anybody know how this should be layed out ?

    If you want to use ArcosNET.DO from ArcosNET.BO then add a project reference. Under the ArcosNET.BO project in the solution explorer there is a folder that says "References", right click, Add, Click the Projects Tab. The ArcosNET.DO project should be listed there, select it. A project reference can be handy because when you change from Debug to Release it will pick up the correct directory for the referenced assembly. Your imports should start working after you do that.


  • Moderators, Society & Culture Moderators Posts: 9,689 Mod ✭✭✭✭stevenmu


    I'd looked in there already but hadn't noticed the projects tab.
    That's exactly what I needed thanks.


Advertisement