|
-
May 27th, 2001, 06:21 PM
#1
Thread Starter
New Member
Problem with different forms?
Well, its like this i have a procedure in form1 and then when i use it on another form it says it doesnt exist, im using the option explicit, and the procedure is public
Tks, Daniel
-
May 27th, 2001, 06:24 PM
#2
PowerPoster
You need to refer to them like thiseven if declared public.
-
May 27th, 2001, 06:30 PM
#3
Thread Starter
New Member
sorry i tries but i couldnt make it work, the names are form1 the procedure name is start, so in the dialog box i tries form1.start it gives the error method or data not found
tks again
-
May 27th, 2001, 06:35 PM
#4
PowerPoster
I just tried it in VB and it works fine. This is what I did...
This code is in Form1
Code:
Public Sub Start()
MsgBox "I am starting!!"
End Sub
This code is in form2 attached to a command button
Code:
Private Sub Command1_Click()
Form1.Start
End Sub
When the button on form2 is clicked, the message box shows fine.
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
|