tags:

views:

164

answers:

1

Hi all. I have Access Form with some Text fields and one Button. Is there any posibility to execute VBA function with passed parameters from Access Form: on button Click? I know that I can exectute Macro but this doesnt resolve my problem. I need to execute VBA. Thanks in advance.

+3  A: 

If you have the VBA function/sub in a module as public you can call the function/sub in the click event on the form.

astander
But how to do that? I have module: AccessHelper and public function named: InertTest(Foo As String)On OnClick event im tying to insert: "AccessHelper.InsertTest([TextField])" but this doesnt work for me :(
dario
what is the error you are getting?
astander
Ok, it works! I need to go to VBA Editor and select Microsoft Office Access Class Objects node instead of writing function name in Button OnClick property page.
dario