How to call a form in another project

R

Robert Gage

Hello All
Can anyone tell me in a single solution how to call a form in another
project?
I have a large solution made up of several projects and need to call back
and forth betweem them

TIA
 
H

Herfried K. Wagner [MVP]

Robert Gage said:
Can anyone tell me in a single solution how to call a form in another
project?
I have a large solution made up of several projects and need to call back
and forth betweem them

Add a reference to the other project to your project, then import the
namespace containing the form class you want to instantiate and create an
instance as you do it with forms defined in the project:

\\\
Imports ClassLibrary1
....
Dim f As New Form1()
f.Show()
///
 
R

Robert Gage

Thank You

Herfried K. Wagner said:
Add a reference to the other project to your project, then import the
namespace containing the form class you want to instantiate and create an
instance as you do it with forms defined in the project:

\\\
Imports ClassLibrary1
...
Dim f As New Form1()
f.Show()
///
 

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

Top