Go Back   CodingForums.com > :: Computing & Sciences > Computer Programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 06-16-2009, 11:02 PM   PM User | #1
jhouns
New Coder

 
Join Date: Aug 2008
Posts: 14
Thanks: 2
Thanked 0 Times in 0 Posts
jhouns is an unknown quantity at this point
Question MS Access 2000, VB module invalid qualifier

Okay i am currently working on a current colleges database (assisting the guy making it as he does not know VB :P) i have put in a system that would work perfectly but in order to cut down space (its very primitive to allow them to easily edit it in the future) i have set up a little one of my own to test out stuff on before attempting on their's. (bit of history in case you were interested )

Here is the button Code

Code:
Private Sub btn_1_Click()
module = record.lol("frm_Table1", "btn_1", "Label_10", "Label_11")
DoCmd.OpenModule (module)
End Sub
---------------------
NOTE: usually i name things better this being small and temporary i dont care please dont comment lol we are all lazy really =]
---------------------

the module code is here:

Code:
Public Function lol(formn As String, button2 As String, label1 As String, label2 As String)
Dim l2 As String
Dim formName As String

formName = formn

l2 = "btn_" + button2
formn.button2.Caption = "Completed"
formName.label1.Caption = "complete 1"
formName.label2.Caption = "complete 2"
End Function
this is 'lol("form name", "button name", "label1 name", "label2 name")'
understood? (if not just say) right then the problem is when i press the button that i get an error

Quote:
Compile Error: Invalid qualifier
The yellow bar is highlighting
Quote:
Public Function lol(formn As String, button2 As String, label1 As String, label2 As String)
and also 'formn' becomes highlighted, i cannot find a solution to this problem, does anyone have any ideas?

Thanks in advance

~Jon~
jhouns is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 08:05 AM.


Advertisement
Log in to turn off these ads.