Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do I pass an object name to another form?
Message
 
To
03/04/2001 09:15:27
GW Gross
{Banned by Information Security Policy}
Lake Mary, Florida, United States
General information
Forum:
Visual Basic
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00490967
Message ID:
00491323
Views:
8
>>If you have a seperate form for each report, I am sure that Forms.Add can do the job for you because you can pass a string to this method.
>
>
>Eric,
>
>I have not used the Forms.Add method before. Any tips on where I should go look to figure it out.

It should be simple in your case. See this example:
Private Sub Command1_Click()
Dim x As String
Dim NewForm As Form

    x = "form2"
    Set NewForm = Forms.Add(x)
    NewForm.Show
End Sub
Éric Moreau, MCPD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Moer inc.
http://www.emoreau.com
Previous
Reply
Map
View

Click here to load this message in the networking platform