Application.run Macro Code Problem

T

Todd Huttenstine

Hey


Below is my code to run a procedure SMSClose in the
SMSClose module of the workbook "Book1.xls".

Application.Run "'" & TargetWB.Name & "'" & "!SMSClose" &
Chr(34)

Workbook "Book1.xls" is the book stored in variable
TargetWB.

When I go to run this code I get the following debug error:
Run-Time error '1004':
The macro "Book10'!SMSClose'" cannot be found.

What am I doing wrong?


Thank you
Todd Huttenstine
 
T

Todd Huttenstine

hey guys, I got it. It was a SYNTAX problem.

Application.Run "'" & TargetWB.Name & "'!SMSFinish"
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top