Sign in to follow this  
Followers 0
slightly_abnormal

how do i get my app to always stay on top?

10 posts in this topic

#1 ·  Posted (edited)

Hello there..

I've tried various mixtures of codes to get my program to always be on top of other windows, but it's not working out.. e.g. heres an example..

if processexist ("swatblatter.exe") or ("autoit3.exe") then
opt ("WinTitleMatchMode", 2)
WinSetState ("swatblatter", "", @SW_SHOW)
winactive("swatblatter")
winactivate("swatblatter")
endif

opt ("WinTitleMatchMode", 2)
WinSetState ("swatblatter", "", @SW_SHOW)
winactive("swatblatter")
winactivate("swatblatter")

thanks for such a wonderful program!

appreciate the help!

Edited by slightly_abnormal

Share this post


Link to post
Share on other sites



WinSetOnTop ( "swatblatter", "", 1 )

window still doesn't stay on top :o

Is this your own script, or external application?


SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

#5 ·  Posted (edited)

Is this your own script, or external application?

my own script. i'm using 3.1.1

Edited by slightly_abnormal

Share this post


Link to post
Share on other sites

You using guicreate?

If so have you tried $WS_EX_TOPMOST as the extended style?


SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

#7 ·  Posted (edited)

You using guicreate?

If so have you tried $WS_EX_TOPMOST as the extended style?

how?

$Form2 = GUICreate("window", 500, 500, 302, 218, , $WS_EX_TOPMOST)

I got errors.. :o

Edited by slightly_abnormal

Share this post


Link to post
Share on other sites

how?

$Form2 = GUICreate("window", 500, 500, 302, 218, , $WS_EX_TOPMOST)

I got errors.. :o

$Form2 = GUICreate("window", 500, 500, 302, 218, -1, $WS_EX_TOPMOST)

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

how?

$Form2 = GUICreate("window", 500, 500, 302, 218, , $WS_EX_TOPMOST)

I got errors.. :o

oh I got it..

$Form2 = GUICreate("Windowizer", 390, 300, 302, 218, BitOR($WS_OVERLAPPEDWINDOW, $WS_CLIPSIBLINGS), $WS_EX_TOPMOST)

Your way is better though..

gracias very much, grafost.. :geek:

Edited by slightly_abnormal

Share this post


Link to post
Share on other sites

One more thing..

How can I make a toggle so that I can enable/disable topmost? :o

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0