Reputation: 527
For example, I've got Solution1
with WinFormProject1 and simple Form1
with one Open
button, and I want when this button is clicked , to open Solution2
WinFormProject2 Form1
.
How can I accomplish this ? Thank you!
Upvotes: 1
Views: 413
Reputation: 2546
You need to add the Assembly containing Form1
from Solution2
as an external Reference in the WinFormProject1
, as Ron Beyer said.
The assembly will be copied to the directory of WinFormProject1
and you will be able to use WinFormProject2.Form1
from your code. Note that since it will be copied there will be no synchronization between the two solutions, and you will need to manually update the copy of the Assembly containing WinFormProject2.Form1
into Solution1
, if needed.
There is no way of doing that while keeping the two in sync and in two separate solutions, you must choose one or the other.
Upvotes: 1