multiform windows app in VB .NET

bigpoppapumpg

Member
Oct 8, 2003
46
0
0
I'm trying to build a windows app with multiple forms. in project explorer i'm right clicking the current project, add->add existing item. then I select a form, but now the project won't build. I get these errors:

'Form1' is ambiguous in the namespace 'WindowsApplication1'.

'Sub Main' was not found in 'WindowsApplication1.Form1'.

Resources 'Form1.resx' and 'MathCalculator.resx' have the same manifest resource name 'WindowsApplication1.Form1.resources'.


am I not adding forms to my project correctly?
 

Descartes

Lifer
Oct 10, 1999
13,968
2
0
You're trying to add the same form that's already there to the project. If you want to add a new form, you don't add an existing item; rather, create a new one.
 

Nothinman

Elite Member
Sep 14, 2001
30,672
0
0
My first guess would be both are named Form1 and it can't differentiate between the two.
 

bigpoppapumpg

Member
Oct 8, 2003
46
0
0
I considered that, what is strange is when I rename a form in project explorer the form name in the code editor is still 'form1' even if I renamed it to something else.
 

alocurto

Platinum Member
Nov 4, 1999
2,174
0
76
incase u are still montioring this. The form file name and class name can be different.