|
-
July 3rd, 2001, 12:53 PM
#1
New doesn't work
I have the following code in an mdi form:\
private Sub new_Click()
Dim a as Form1
set a = new Form1
a.Caption = "new Script"
a.show
End Sub
And i also have a module with a function:
Function insertfunc()
Dim func as string
Dim ch
Dim func2 as string
ch = Chr(10)
func = InputBox("Enter function name")
func2 = "function " & func & "()" & ch & "{" & ch & "" & ch & "}"
insertfunc = func2
End Function
Everything works fine. I can create a new form, the function is called without any errors. But when i try to create another new form, it won't create another new one unless the first one is closed. I have the same code in other programs and it works fine. What am i doing wrong? I'll give ratings
--Ant
--------------------------------------------------
check out my newest freeware
E-mail me at: [email protected]
for the address
-
July 3rd, 2001, 01:00 PM
#2
Re: New doesn't work
' Declared somewhere'
Dim fFrm as frmYourHugeForm'
public Sub ShowAForm()'
set fFrm = new fFrm'
Load fFrm'
fFRM.show
End Sub
Iouri Boutchkine
[email protected]
-
July 3rd, 2001, 05:23 PM
#3
Re: New doesn't work
It gives me an error that says: User-defined type not defined. What's that mean?
--Ant
--------------------------------------------------
check out my newest freeware
E-mail me at: [email protected]
for the address
-
July 5th, 2001, 08:15 AM
#4
Re: New doesn't work
I think that the line
Dim fFrm as frmYourHugeForm'
gives you the problem
Rewrite it as
Dim fFrm as Form
Iouri Boutchkine
[email protected]
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
|
Click Here to Expand Forum to Full Width
|