Results 1 to 4 of 4

Thread: [RESOLVED] VS2005: How to instantiate Class A in Project A from Project B

  1. #1

    Thread Starter
    Member
    Join Date
    Jan 2006
    Posts
    39

    Resolved [RESOLVED] VS2005: How to instantiate Class A in Project A from Project B

    I have a multi-project solution. I need to instantiate a class in Project B from within Project A. Can this be done? Or have I structured my project incorrectly? I have always in VB6 lumped everything together. Being new to VB.NET I thought this might be possible.

  2. #2
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373

    Re: VS2005: How to instantiate Class A in Project A from Project B

    select project A in the solution explorer, right click and select "Add Reference"

    when the next screen comes up, click on the projects tab, and you will see project B in the list (so long as they are infact part of the same solution)

    once you add the reference, you can create the class from projB in projA. VS will also take care of automatically copying the compiled DLL from projB into the bin folder of projA

  3. #3

    Thread Starter
    Member
    Join Date
    Jan 2006
    Posts
    39

    Re: VS2005: How to instantiate Class A in Project A from Project B

    That appeared to have worked. VB.NET is deep. I can understand the reservation of many programmers to convert.

    Many thanks, Klein.

  4. #4
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373

    Re: [RESOLVED] VS2005: How to instantiate Class A in Project A from Project B

    nah.... once you get into it.. you will never want to open VB6 again.. I know I never do

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width