Hi,

I'm wondering if it's possible to make the "ShellExecute" command to wait until it finishes it's process?
This is what I want to do: I have a file that I would like to open in it's associated application (for example like a .doc file to be opened in Word). For that I use the ShellExecute function. After the document is opened, a script that I have should be run on the document. How could all that be accomplished with ShellExecute? I just have to wait for ShellExecute to fully open the document and the rest I know how to do (call the script etc.). Or maybe there is an alternative to open the file, without using ShellExecute?

Thanks in advance.