Ideas on doing this idea? Anyone?

01-20-2005, 08:49 PM
I have a new program idea that requires me to somehow load forms, but of course "Load frmMain(Index)" wouldn't work because you can't give forms indexes (or can you)?

Does anyone know a way I can do this still?

01-21-2005, 02:07 AM
Dim myForm(4) As Form
Dim i As Integer
For i = LBound(myForm) To UBound(myForm)
Set myForm(i) = New Form1
Next i

I just tried that and it worked.
Form1 is a normal Form with a CommandButton CommandButton1 on it :D

01-21-2005, 11:14 PM
you can't give forms indexes (or can you)?
All created forms in Visual Basic are part of a forms collection. You can access a particular form using it's collection index.


Interested in reading more:

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum