Sign in to follow this  
Followers 0
kman

GuiCreate & Taskbar

4 posts in this topic




Like this?

#include <GUIConstants.au3>

GUICreate("My GUI",200,200,-1,-1,-1,$WS_EX_TOOLWINDOW)  
GUISetState (@SW_SHOW)     


While 1
    $msg = GUIGetMsg()
    
    If $msg = $GUI_EVENT_CLOSE Then ExitLoop
Wend

Share this post


Link to post
Share on other sites

Thank you for this. I also want to thank Hatcheda and Generator for their help as well with this little project Im trying to do. Let me explain what I am trying to accomplish. We have a program that switches between two locations. I am trying to create an image that will show on the header bar what location is active and nothing if the window is minimized or another application window is active. With help I have been able to use splashimageon to do this but get a flicker of the image based on the sleep time because it is recreating the image. I thought maybe I would try using a gui image as there might be more ways to control the flicker and less overhead of having to install the images on the computers using it. This is my first work with GUI and I am stuck, but whats new? :P Any help with either would be greatly appreciated!

Here is the image code that works well but gets the "flicker":

Opt("WinTitleMatchMode", 2)

$westdest ="C:\Meds\campus\west.gif"
$eastdest ="C:\Meds\campus\east.gif"
Global $Width = 500
Global $Height = 20
    
Run("\\hmmrpt\Meds\MED-Update.exe","\\hmmrpt\Meds")

ProcessWait("hmm.exe")

While 1
    
    

    If WinActive("WEST **MMLIVE**") Then
    $size=WinGetPos("Horizon Meds Manager:")
    Global $X = ((($size[2]/2)-($Width/2))+$size[0])
    Global $Y = (($Height/15)+$size[1])
    SplashImageOn("", $westdest, $Width, $Height, $X, $Y, 17)
Else
    If WinActive("EAST **MMLIVE**") Then
    $size=WinGetPos("Horizon Meds Manager:")
    Global $X = ((($size[2]/2)-($Width/2))+$size[0])
    Global $Y = (($Height/15)+$size[1])
    SplashImageOn("", $eastdest, $WIDTH, $HEIGHT, $X, $Y, 17)
Else 
    SplashOff()
    EndIf
EndIf



    If Not ProcessExists("HMM.exe") Then
    Exit
    EndIf
    Sleep(1000)
WEndoÝ÷ Øw«z+-á!Êx­¯(§»­ÌÊg¬±çn¥«­¢+Ù=ÁÐ ÅÕ½Ðí]¥¹Q¥Ñ±5Ñ¡5½ÅÕ½Ðì°È¤)=ÁÐ ÅÕ½ÐíQÉå%½¹ÕÅÕ½Ðì°Ä¤((¥¹±Õ±ÐíÕ¥
½¹ÍѹÑ̹ÔÌÐì()±½°ÀÌØí]¥Ñ ôÔÀÀ)±½°ÀÌØí!¥¡ÐôÈÀ()]¡¥±Ä)%]¥¹Ñ¥Ù ÅÕ½Ðí]MPÅÕ½Ðì¤Q¡¸($ÀÌØíÍ¥éõ]¥¹ÑA½Ì ÅÕ½Ðí!½É¥é½¸5Ì5¹ÈèÅÕ½Ðì¤(%±½°ÀÌØí`ô   ÀÌØíÍ¥élÉt¼È¤´ ÀÌØí]¥Ñ ¼È¤¤¬ÀÌØíÍ¥élÁt¤(%±½°ÀÌØídô  ÀÌØí!¥¡Ð¼ÄÔ¤¬ÀÌØíÍ¥élÅt¤(%Õ¥
ÉÑ ÅÕ½ÐìÅÕ½Ðì°ÀÌØí]¥Ñ °ÀÌØí!¥¡Ð°ÀÌØí`°ÀÌØíd°ÀÌØí]M}A=AU@°ÀÌØí]M}a}Q=A5=MP¬ÀÌØí]M}a}Q==1]%9=¤(%U%MÑ    ­
½±½È Áá
ÀÀÌ̤(%U%Mѽ¹Ð ÄаÔÔÀ¤(%U%
Ñɱ
ÉÑ1° ÅÕ½Ðí]MP
5AULÅÕ½Ðì°ÄäÀ°´Ä¤(%Õ¥MÑMÑÑ¡M]}M!=¤($)±Í(%]¥¹Ñ¥Ù ÅÕ½ÐíMPÅÕ½Ðì¤Q¡¸($$ÀÌØíÍ¥éõ]¥¹ÑA½Ì ÅÕ½Ðí!½É¥é½¸5Ì5¹ÈèÅÕ½Ðì¤($%±½°ÀÌØí`ô   ÀÌØíÍ¥élÉt¼È¤´ ÀÌØí]¥Ñ ¼È¤¤¬ÀÌØíÍ¥élÁt¤($%±½°ÀÌØídô  ÀÌØí!¥¡Ð¼ÄÔ¤¬ÀÌØíÍ¥élÅt¤($$ÀÌØí½ÍÐõÕ¥
ÉÑ ÅÕ½ÐìÅÕ½Ðì°ÀÌØí]¥Ñ °ÀÌØí!¥¡Ð°ÀÌØí`°ÀÌØíd°ÀÌØí]M}A=AU@°ÀÌØí]M}a}Q=A5=MP¬ÀÌØí]M}a}Q==1]%9=¤($%U%MÑ   ­
½±½È ÁàÌÍ
Ì̤($%U%Mѽ¹Ð ÄаÔÔÀ¤($%U%
Ñɱ
ÉÑ1° ÅÕ½ÐíMP
5AULÅÕ½Ðì°ÄäÀ°´Ä¤($%U%MÑMÑÑ¡M]}M!=¤)±Í(%Õ¥MÑMÑÑ¡M]}!%¤(%¹%)¹%)M±À ÄÀÀÀ¤)]¹

Share this post


Link to post
Share on other sites

Any thoughts or ideas on this? Thank you.

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