Can't get dialog to close

Technical support and scripting issues

Moderators: JRL, Dorian (MJT support)

Post Reply
User avatar
Phil Pendlebury
Automation Wizard
Posts: 543
Joined: Tue Jan 16, 2007 9:00 am
Contact:

Can't get dialog to close

Post by Phil Pendlebury » Wed Nov 07, 2012 10:52 pm

Greetings,

I'm probably being really dumb here but this is an older script I recently updated to the new dialog system and I am having a small problem.

The dilaog will not close using Close>Dialog command

Well, it will close when the script is run with MSched but when run from as EXE file the dialog does not close (so I have had to setdialog property disabled instead).

A bit of code that may help:

DECLARE DIALOGS
SET UP HANDLERS

Show>Dialog1,

VARIOUS SUB ROUTINES

An SRT CONTAINS THIS:

IF>%TESTOK%=1
GOSUB>MOVE
ENDIF


THE MOVE SRT CONTAINS THIS:

CloseDialog>Dialog1
SetDialogProperty>Dialog1,,Enabled,False


I have added the Enabled, False because the Dialog doesn't close when the script is an EXE file. And there is another dialog that takes over and displays actions. If the main dialog is messed with during that period everything goes pear shaped.

I am sure this may be to do with modal / non-modal but why would it work when MSched is running but not close when run as an EXE?

And how do I get the Dialog1 to close at a specific place when run as an EXE file?

Any help appreciated thank you.

P :-)
Last edited by Phil Pendlebury on Wed Nov 07, 2012 11:02 pm, edited 1 time in total.
Phil Pendlebury - Linktree

User avatar
Phil Pendlebury
Automation Wizard
Posts: 543
Joined: Tue Jan 16, 2007 9:00 am
Contact:

Post by Phil Pendlebury » Wed Nov 07, 2012 11:02 pm

Oh - Ok is this the correct solution?

Show>Dialog1
Label>loop
wait>.1
Goto>loop


BLAH BLAH

CloseDialog>Dialog1
Phil Pendlebury - Linktree

Post Reply
Sign up to our newsletter for free automation tips, tricks & discounts