Home All Groups Group Topic Archive Search About

How To? import vb net forms ???

Author
30 Jun 2005 10:23 PM
GerryLowry1(905)825-9582{AbilityBusinessComputerServices)
In Microsoft Access, importing and exporting forms from one .mdb to another is very, very easy to
do.

VB.NET seems to be quite difficult, probably because I am doing something wrong.

Steps to recreate (Visual Studio 2003)
----------------------------------------

Create VB Project                       vb1
Add a few controls to the default form
Compile ... no problem

Create VB Project                       vb2
Rename the default form "Form2"
Add a few controls to the default form
Compile ... no problem

copy Form2.vb into vb1's folder.
compile vb1 .... you get compilation errors

????????????????????????

What is the correct technique to import and export vb forms?

thank you
regards
gerry

Author
30 Jun 2005 10:37 PM
Shawn
copy form2.vb and form2.resx to the first folder.

Add form2 from the solution explorer.

Make sure that form2 in code view is "public class form2". When you
simply rename the form it won't change the class name from "public
class form1"
Author
30 Jun 2005 10:37 PM
Oenone
GerryLowry1(905)825-9582{AbilityBusinessComputerServices) wrote:
> copy Form2.vb into vb1's folder.
> compile vb1 .... you get compilation errors

What are the compilation errors?

--

(O) e n o n e
Author
1 Jul 2005 7:00 AM
Peter Proost
Right click on your project and choose add existing item, then browse to the
form folder you want to add and select the .vb file and the .resx files, if
you want changes you make in one of the forms to show up in the other one
choosel link file instead of open (click on the arrow next open)

Hth Greetz Peter


--
Programming today is a race between software engineers striving to build
bigger and better idiot-proof programs, and the Universe trying to produce
bigger and better idiots. So far, the Universe is winning.

Show quoteHide quote
"Oenone" <oen***@nowhere.com> schreef in bericht
news:bv_we.110$qt3.75@newsfe5-gui.ntli.net...
> GerryLowry1(905)825-9582{AbilityBusinessComputerServices) wrote:
> > copy Form2.vb into vb1's folder.
> > compile vb1 .... you get compilation errors
>
> What are the compilation errors?
>
> --
>
> (O) e n o n e
>
>