Tell me more ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

So, I have an excel macro I need to run after a SAP macro is finished. The SAP macro works fine without the inclusion of the Excel macro code. I'm not sure if it is how the sub routines are called because I do not know that much about VBScript. SAP automatically opens the file when it finishes the macro, so it will already be open.

I am getting a 800A03EE code right now expecting a ). Could someone please help with this?

Here is the full code of the VBS file.

http://pastebin.com/HVV7B2Ry

share|improve this question
When does the error occur? Is the error in the vbscript or in the VBA? On which line? – Tim Williams Jun 25 '12 at 18:34
Line 68 Char 49 Expected ')' – tluck234 Jun 25 '12 at 18:40
And where is the error from - vbscript or VBA ? Since you don't seem to be showing the entire script, the line number isn't much help. What's on that line? – Tim Williams Jun 25 '12 at 18:46
Sorry, it is VBScript. What I posted on pastebin is the entire VBScript file. It is ran as a process from the C# application. – tluck234 Jun 25 '12 at 18:47
Macro1() is a VBA macro - it belongs in Excel unless you modify it to run in vbscript. For it to run in vbscript (for example) you would need to get a reference to the running Excel instance, and use that to qualify your worksheet references etc. You also can't use named arguments or built-in excel contants in vbscript. – Tim Williams Jun 25 '12 at 20:02
show 3 more comments

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.