Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #10652


    This is a simplified test macro, for reproducing a problem I encountered:

    WshShell = new ActiveXObject("WScript.Shell");

    var app = editor.FullName;

    for (var ii=0; ii<5; ii++)
    if (!confirm("Continue?")) Quit();
    WshShell.Run (""" + app + """);

    If as expected, every time before a new EmEditor window is launched, there should be a confirmation prompt.
    But, if I close one of the EmEditor windows launched by this macro, and then confirm the prompt, the For loop will go on running to its end without any pause, all the rest of the EmEditor windows will be launched with no confirmation prompt.

    There’s no such a problem if EmEditor is running more than one process, or if WshShell.Popup is used instead of the Confirm method.


    Yutaka Emura

    Hi LTT,

    I am not sure your test environment. Is the “Enable Tabs” set? If you are using the Tabs, you won’t be able to close a new tab that is created during the macro because the “Confirm” dialog box is the foreground window. If the Enable Tabs is not set, you can close a new created window during the macro, but the macro will continue as expected. Please explain the detail procedure to reproduce the issue.

    Thank you,



    Sorry, I found the reason:
    I have an event-driven macro that runs at [Group Window Closed] etc. So this problem was because another macro ran during the macro running. (This is a limitation?)



    To all,
    You might have problems caused by your event-driven macros. Try and see if you need this macro:

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.