Apr 18, 2002 #1 rdharmar IS-IT--Management Joined Jun 20, 2001 Messages 54 Location US I need to pass a form as an arguments to sub routine in a Module. I get a type mismatch error? What's wrong with this? Thanks! in the Form module: loadListBox(frmABC) in the BAS Module: Sub loadListBox(formName as form) End Sub
I need to pass a form as an arguments to sub routine in a Module. I get a type mismatch error? What's wrong with this? Thanks! in the Form module: loadListBox(frmABC) in the BAS Module: Sub loadListBox(formName as form) End Sub
Apr 18, 2002 #2 CajunCenturion Programmer Joined Mar 4, 2002 Messages 11,381 Location US change the syntax of the call to either one of the following loadListBox frmABC ' no parens or call loadlistbox (frmABC) ' with parens Good Luck ------------ Select * from Users where Clue > 0 0 rows returned Upvote 0 Downvote
change the syntax of the call to either one of the following loadListBox frmABC ' no parens or call loadlistbox (frmABC) ' with parens Good Luck ------------ Select * from Users where Clue > 0 0 rows returned
Apr 18, 2002 #3 Nachocat Programmer Joined Mar 20, 2002 Messages 5 Location US Try something like this... in the Form module: Call loadListBox(frmABC) in the BAS Module: Sub loadListBox(Source as Control) If TypeOf Source Is Form Then With Source .Caption = "This is My Form" End With End If End Sub Hope this helps Upvote 0 Downvote
Try something like this... in the Form module: Call loadListBox(frmABC) in the BAS Module: Sub loadListBox(Source as Control) If TypeOf Source Is Form Then With Source .Caption = "This is My Form" End With End If End Sub Hope this helps
Apr 18, 2002 Thread starter #4 rdharmar IS-IT--Management Joined Jun 20, 2001 Messages 54 Location US Thanks guys! Upvote 0 Downvote