858RE: [cc2-dev-l] Re: since SetScriptCopy is non-blocking ....
- Oct 21, 2010
The ExecScriptCopy will put a command into the macro queue. The next command in the macro queue (might not be yours) will be executed *after* your command returns to the command line. The only way to do this is therefore:
1. Call AbortAllScripts() to make sure the macro queue is empty
2. Call ExecScriptCopy() with the macro to execute and your command name to return to the XP
3. Call CmdEnd() to terminate your command
4. Detect that you are reentering your command after the macro has been executed.
The alternative is to use MYCMD and then return to MYCMD2 (but then you have to manually update the repeat command).
Do you really need to call a macro command?
OK this is what I've tried ... to no avail:
while(AskScript() != 0)
int _stdcall _AskScript()
__asm mov s, eax;
#define AskScript _AskScript
I really want to get past this issue, so please help!!!!!
--- In email@example.com, "Larry" <saunderl@...> wrote:
>trial-and-error, I've learned that SetScriptCopy is not blocking.
> Hey Everyone,
> I need some help. I'm using SetScriptCopy and after a lot of
>the script is finished (ie, I need to block further execution of my code until SetScriptCopy is done.
> I need to be able to call SetScriptCopy and not leave the function until
>into a tight loop checking (AskScript) after the call to SetScriptCopy?
> And after looking in FCW32.TXT that is fairly obvious. :-)
> Mainly because there exists two other commands:
> 1 - SetScriptsDone
> 2 - AskScript
> Would it be better so use the callback function (SetScriptsDone) or go
>callbacks are not my strong point.
> The reason I ask (as everyone knows, I'm not an expert at C/C++) is that
> How would you use SetScriptsDone in a blocking manner?
> How would I use AskScript in a blocking manner?
> If anyone has examples and the Glue rountines to call them, thanks!
> L. Lee Saunders
- << Previous post in topic Next post in topic >>