kessmiller
New member
- Local time
- Yesterday, 21:49
- Joined
- Mar 21, 2011
- Messages
- 8
I have a macro that runs several steps and then I want it to export a file to text using a spec. The specs no longer work in the macros so I wrote a module to do the export. I can't get the macro to call the module correctly. I've broken it down to just the one command in the macro calling the module, but I can't get it to work.
I'm a newbie on modules and functions and know whatever is wrong with this is painfully stupid, but I can't find it. I have another module that looks just like it as far as I can see and it works - this one doesn't.
Function mod_karla()
On Error GoTo mod_karla_Err
MsgBox "Module mod_karla() has run"
mod_karla_Exit:
Exit Function
mod_karla_Err:
MsgBox Error$
Resume mod_karla_Exit
End Function
I have macro RunModuleTest set up that just has the one command to run the module:
RunCode Function Name Mod_karla()
When I run it I get an error that says 'The expression you entered has a function name that Microsoft Access can't find.' The macro single step box shows Macro name as RunModuleTest, action name RunCode, Arguments mod_karla(),error number 2425.
I'm a newbie on modules and functions and know whatever is wrong with this is painfully stupid, but I can't find it. I have another module that looks just like it as far as I can see and it works - this one doesn't.
Function mod_karla()
On Error GoTo mod_karla_Err
MsgBox "Module mod_karla() has run"
mod_karla_Exit:
Exit Function
mod_karla_Err:
MsgBox Error$
Resume mod_karla_Exit
End Function
I have macro RunModuleTest set up that just has the one command to run the module:
RunCode Function Name Mod_karla()
When I run it I get an error that says 'The expression you entered has a function name that Microsoft Access can't find.' The macro single step box shows Macro name as RunModuleTest, action name RunCode, Arguments mod_karla(),error number 2425.