-
link forms in different projects
when i press a button in form1 of project1 i want to open form1 of project2
i want the code.
-
Re: link forms in different projects
In VB all form objects are private ot the project and are not accessible to
other projects. Yet there is a workaround for the problem.
Assuming Project1 is a Standard EXE and project2 is an ActiveX DLL
Add a Class Module to Porject2 with Instancing property set to MultiUse.
And Define the following function
Private mfProj2Form as Project2.Form1
Public Function ShowForm() as Object
set mfProj2Form = new Project2.Form1
Load mfProj2Form
mfProj2Form.Show
set ShowForm = mfProj2Form
End Function
In Project1, in the Button Click event create an object of Project2.Class1
and call this method and save a reference to the form object returned by
the method.
- Jaideep
"vb sisko" <tomaras@mail.gr> wrote:
>
>when i press a button in form1 of project1 i want to open form1 of project2
>i want the code.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks