Hello,
My VBA macro runs a VBscript to pull a report from SAP. I need to pause the vba script to account for the time it takes the VBscript to fully run. I was using a function that waits for the file to be saved to my desktop, but this SAP report can't be saved and exported. It can only be exported to excel. So I was thinking of another way of checking to see if the VBscript is done running. That is looping an activate wb function. If the wb activates, then continue the vba script. If the wb doesn't activate, then pause for a couple of seconds and try to activate the wb again.
The code below waits for the file to exist on my desktop. I'm hoping someone can assist me in editing the code to loop activating the wb instead of checking for the file on my desktop, or point me in the right direction as to what needs edited.
Bookmarks