Can a Dialog be made "Impossible to Minimize"?
Moderators: Dorian (MJT support), JRL
Can a Dialog be made "Impossible to Minimize"?
Hi Marcus,
Thanks for the quick reply to Can a Dialog be made to "STAYONTOP"?.
That lets us make a dialog that no other window can appear in front of. That's good, however hitting "Windows Key"-D still minimizes the dialog and its gone from view.
I need a dialog that can't be minimized... exactly like the "SMTPSendMail Status Window" behaves.
Is there a way to make a dialog "Impossible to Minimize"?
Thanks
Thanks for the quick reply to Can a Dialog be made to "STAYONTOP"?.
That lets us make a dialog that no other window can appear in front of. That's good, however hitting "Windows Key"-D still minimizes the dialog and its gone from view.
I need a dialog that can't be minimized... exactly like the "SMTPSendMail Status Window" behaves.
Is there a way to make a dialog "Impossible to Minimize"?
Thanks
jpuziano
Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post -
Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post -
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
No, I don't think that's possible. I'm actually a bit puzzled because a) my SMTP Status Windows *DOES* minimize when I hit Windows-D, and b) the flags used in the SetWindowPos function that I provided are identical to what are used internally on the SMTP Status Window. Therefore there is no difference to the way these windows are set up. As I said, in my case ALL windows minimize with Windows-D - including the status window!
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
In a non modal dialog the line:
WindowAction>0,[Dialog Title]
Inserted into the GetDialogAction> loop will prevent the dialog from staying minimised.
For a modal dialog a second script or an executable could be spawned to perform the same function.
A secondary script like this:
Label>start
WindowAction>0,[Dialog Title]
Wait>0.01
Goto>start
Hope this helps,
Dick
WindowAction>0,[Dialog Title]
Inserted into the GetDialogAction> loop will prevent the dialog from staying minimised.
For a modal dialog a second script or an executable could be spawned to perform the same function.
A secondary script like this:
Label>start
WindowAction>0,[Dialog Title]
Wait>0.01
Goto>start
Hope this helps,
Dick
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Very smart. Good thinking!
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
Hi Marcus,mtettmar wrote:No, I don't think that's possible. I'm actually a bit puzzled because a) my SMTP Status Windows *DOES* minimize when I hit Windows-D, and b) the flags used in the SetWindowPos function that I provided are identical to what are used internally on the SMTP Status Window. Therefore there is no difference to the way these windows are set up. As I said, in my case ALL windows minimize with Windows-D - including the status window!
I tried it again and yes you're right, the SMTP Status Windows does indeed minimize on hitting Windows-D... I had tried it on a sluggish PC that took so long to respond, the SMTPSendMail command would finish in my test script before the SMTP Status Window had a chance to minimize... it appeared impervious to Windows-D.
Hi JRL,
Your solution is clever and exactly what I needed, thank you so much. If ever a "Macro Scheduler T-Shirt" is produced, I think you should get a free one. I owe you at least a beer... thanks again!!!
jpuziano
Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post -
Note: If anyone else on the planet would find the following useful...
[Open] PlayWav command that plays from embedded script data
...then please add your thoughts/support at the above post -
Hello to all and 1st off this forum is a godsend great work to all here...as you can tell by my script example below im brand new to macro scheduler but find it a facinateing tool with endless possibilities
my question has to do with this keeping the dialog on top code ive tried it several ways and some it has kept it on top but executed the script imediately rather than waiting for the button command this is just a simple script that waits for 1 button to appear then clicks it...could someone please show me how to incorperate the stay ontop code into this to make it work as it is designed to do.....ty in advance for any and all input.
my question has to do with this keeping the dialog on top code ive tried it several ways and some it has kept it on top but executed the script imediately rather than waiting for the button command this is just a simple script that waits for 1 button to appear then clicks it...could someone please show me how to incorperate the stay ontop code into this to make it work as it is designed to do.....ty in advance for any and all input.
Code: Select all
setfocus> in Big*
movewindow> in Big*,0,0
Dialog>Dialog1
Caption=BigTeaser1.0
Top=469
Width=165
Left=0
Height=95
Label=Press Shift + Esc to Stop,20,35
Button=start,0,5,75,30,2
Button=exit,80,5,75,30,3
EndDialog>Dialog1
show>Dialog1,result
if>result=2,start
if>result=3,exit
end
Label>start
Label>colors
GPC>235,280,reb
IF>%reb%=16777215,reb
Goto>colors
label>reb
MouseMove>235,280
wait>.4
lclick
goto>start
label>exit
-
- Junior Coder
- Posts: 24
- Joined: Mon Nov 01, 2004 1:30 pm
See remarks:
Hope this helps,
Dick
Hope this helps,
Dick
Code: Select all
setfocus> in Big*
movewindow> in Big*,0,0
Dialog>Dialog1
Caption=BigTeaser1.0
Top=469
Width=165
Left=0
Height=95
//Label=Press Shift + Esc to Stop,20,35
//Fixed button results
Button=start,0,5,75,30,3
Button=exit,80,5,75,30,2
EndDialog>Dialog1
//to make this stay on top you must use
//a non-modal dialog. See dialog help for
//modal vs non-modal
show>Dialog1
Label>ActionLoop
GetDialogAction>Dialog1,result
if>result=3,start
if>result=2,exit
//Wait added to prevent tight loop
Wait>0.01
//Window Action set to 0 and embedded into the
//ActionLoop of the non-modal dialog will prevent
//the window named BigTeaser1.0 from staying minimized
//for more than a couple hundredths of a second
WindowAction>0,BigTeaser1.0
Goto>ActionLoop
Label>start
Label>colors
//If you want the window to stay on top during the long(?)
//wait for the pixel to become the correct color
//you'll need teh same WindowAction> line in the "colors" loop
WindowAction>0,BigTeaser1.0
//Wait added to prevent tight loop
Wait>0.01
GPC>235,280,reb
IF>%reb%=16777215,reb
Goto>colors
label>reb
MouseMove>235,280
wait>.4
lclick
//Changed to goto>ActionLoop or you have an endless loop.
//you might have an endless loop anyway with the colors loop
//if the specified pixel never turns to the specified color.
//Goto>start
goto>ActionLoop
label>exit
talking about the on top code i am wondering what the problem is with my script all help would be appreciated.
movewindow>in Big*,0,0
let>TIMES=0
Dialog>Dialog3
Caption=Roulette Player 1.1
Top=321
Width=173
Left=470
Height=87
Label=0,40,32
Button=Start,0,0,75,25,3
Button=%TIMES%,80,0,75,25,2
EndDialog>Dialog3
Show>Dialog3
label>asd
GetDialogAction>Dialog3,result
If>result=3,Colors1
if>result=2,Exit
goto>asd
Label>Colors1
ResetDialogAction>Dialog3
Label>Colors
Let>Dialog3.msLabel0=%TIMES%
GetDialogAction>Dialog3,result
If>result=3,Colors
if>result=2,Exit
GPC>234,278,Bm
if>%Bm%=16777215,Bm
goto>Colors
label>Bm
mou>234,278
lcl
mou>556,426
lcl
add>TIMES,1
goto>Colors
label>Exit
movewindow>in Big*,0,0
let>TIMES=0
Dialog>Dialog3
Caption=Roulette Player 1.1
Top=321
Width=173
Left=470
Height=87
Label=0,40,32
Button=Start,0,0,75,25,3
Button=%TIMES%,80,0,75,25,2
EndDialog>Dialog3
Show>Dialog3
label>asd
GetDialogAction>Dialog3,result
If>result=3,Colors1
if>result=2,Exit
goto>asd
Label>Colors1
ResetDialogAction>Dialog3
Label>Colors
Let>Dialog3.msLabel0=%TIMES%
GetDialogAction>Dialog3,result
If>result=3,Colors
if>result=2,Exit
GPC>234,278,Bm
if>%Bm%=16777215,Bm
goto>Colors
label>Bm
mou>234,278
lcl
mou>556,426
lcl
add>TIMES,1
goto>Colors
label>Exit
-
- Pro Scripter
- Posts: 58
- Joined: Mon Jun 27, 2005 7:03 am
- Location: Switzerland