Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

.Net Namespaces

  • 14-03-2005 04:58PM
    #1
    Moderators, Society & Culture Moderators Posts: 9,688 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, Registered Users 2 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,688 Mod ✭✭✭✭stevenmu


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


Advertisement