Jump to content

Image Refresh In GUI make screen flicker


Greenseed
 Share

Recommended Posts

Hi! im planning to make a really big and dynamic logon script and i wanna a nice very nice interface! my interface or MainGUI is made with image all button or information are made with image! the probleme is when i have to change a image for another to make the interface dynamic. the change of the image work well but i got a screen flicker on some image when i change it! im wondering if someone know how to bypass this screen flicker! thx in advance for the help!

i post the file with this topic! the file is a little big 470Kb because of images!

Greenseed

ihave removed the attachement du to restriction!

to get it and help me out just send me a PM and i send you the file

Edited by Greenseed

GreenseedMCSE+I, CCNA, A+Canada, QuebecMake Love Around You.

Link to comment
Share on other sites

ok i have found something!

if i hide and show my control with ControlShow("Wintitle","text",controlid) and ControlHide()

the flicker seam to disapear but not completely at 90%

i need 100% hehe B) if some one can help please i post my update code for this one! for the image refear to my first post the attachement!

#include <guiconstants.au3>
Opt("CaretCoordMode", 1)       ;1=absolute, 0=relative
Opt("ExpandEnvStrings", 0)   ;0=don't expand, 1=do expand
Opt("MouseClickDelay", 10)   ;10 milliseconds
Opt("MouseClickDownDelay", 10) ;10 milliseconds
Opt("MustDeclareVars", 0)     ;0=no, 1=require pre-declare
Opt("PixelCoordMode", 1)       ;1=absolute, 0=relative
Opt("RunErrorsFatal", 0)       ;1=fatal, 0=silent set @error
Opt("SendAttachMode", 0)       ;0=don't attach, 1=do attach
Opt("SendCapslockMode", 1)   ;1=store and restore, 0=don't
Opt("SendKeyDelay", 8)       ;5 milliseconds
Opt("SendKeyDownDelay", 1)   ;1 millisecond
Opt("TrayIconDebug", 1)     ;0=no info, 1=debug line info
Opt("TrayIconHide", 0)       ;0=show, 1=hide tray icon
Opt("WinWaitDelay", 500)       ;250 milliseconds
Opt("WinDetectHiddenText", 0)  ;0=don't detect, 1=do detect
Opt("WinSearchChildren", 1) ;0=no, 1=search children also
Opt("WintitleMatchMode", 1) ;1=start, 2=subStr, 3=exact, 4=...
Opt("ColorMode", 0)

$imagespath = @ScriptDir&"\Images\"
Dim $guiimages[7][3]



$MainGUI = GUICreate("GreenScript v2.0a", 640, 504, 197, 122, $DS_SETFOREGROUND, BitOR($WS_EX_TOOLWINDOW,$WS_EX_TOPMOST,$WS_EX_CLIENTEDGE))
GUISetCursor (7)
$BackGroundIMG = GUICtrlCreatePic($imagespath&"MainGUI.jpg", 0, 0, 640, 480)
GUICtrlSetCursor ($BackGroundIMG, 7)
$ComputationACTIVE = GUICtrlCreatePic($imagespath&"Button\ComputationACTIVE_281x55 copy.jpg", 0, 17, 281, 55)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$AquisitionACTIVE = GUICtrlCreatePic($imagespath&"Button\AquisitionACTIVE_280x49.jpg", 0, 84, 280, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ApplicationACTIVE = GUICtrlCreatePic($imagespath&"Button\ApplicationACTIVE_298x52 copy.jpg", 0, 145, 298, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$AdjustementACTIVE = GUICtrlCreatePic($imagespath&"Button\AdjustementACTIVE_304x52 copy.jpg", 0, 217, 304, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ConnectionACTIVE = GUICtrlCreatePic($imagespath&"Button\ConnectionACTIVE_282x52 copy.jpg", 0, 279, 282, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ImprimantesACTIVE = GUICtrlCreatePic($imagespath&"Button\ImprimantesACTIVE_336x52 copy.jpg", 0, 342, 336, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ExecutionACTIVE = GUICtrlCreatePic($imagespath&"Button\ExecutionACTIVE_358x52 copy.jpg", 0, 404, 358, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ExecutionOK = GUICtrlCreatePic($imagespath&"Button\ExecutionOK_363x52 copy.jpg", 0, 405, 363, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ImprimantesOK = GUICtrlCreatePic($imagespath&"Button\ImprimantesOK_343x52 copy.jpg", 0, 341, 343, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ConnectionOK = GUICtrlCreatePic($imagespath&"Button\ConnectionOK_287x52 copy.jpg", 0, 276, 287, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$AdjustementOK = GUICtrlCreatePic($imagespath&"Button\AdjustementOK_303x52 copy.jpg", 0, 214, 303, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ApplicationOK = GUICtrlCreatePic($imagespath&"Button\ApplicationOK_303x52 copy.jpg", 0, 142, 303, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$AquisitionOK = GUICtrlCreatePic($imagespath&"Button\AquisitionOK_269x52 copy.jpg", 0, 79, 269, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ComputationOK = GUICtrlCreatePic($imagespath&"Button\ComputationOK_278x52 copy.jpg", 0, 17, 278, 52)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$Computationerror = GUICtrlCreatePic($imagespath&"Button\Computationerror_303x55 copy.jpg", 0, 14, 303, 55)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$Aquisitionerror = GUICtrlCreatePic($imagespath&"Button\Aquisitionerror_280x49 copy.jpg", 0, 81, 280, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$Applicationerror = GUICtrlCreatePic($imagespath&"Button\Applicationerror_303x49 copy.jpg", 0, 142, 303, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$AdjustementERROR = GUICtrlCreatePic($imagespath&"Button\AdjustementERROR_310x49 copy.jpg", 0, 214, 310, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$Connectionerror = GUICtrlCreatePic($imagespath&"Button\Connectionerror_283x49 copy.jpg", 0, 279, 283, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ImprimantesERROR = GUICtrlCreatePic($imagespath&"Button\ImprimantesERROR_335x49 copy.jpg", 0, 340, 335, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$Executionerror = GUICtrlCreatePic($imagespath&"Button\Executionerror_365x49 copy.jpg", 0, 406, 365, 49)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )
$ButtonDOWN = GUICtrlCreatePic($imagespath&"Button\ButtonDOWN_60x48 copy.jpg", 574, 275, 60, 48)
GUICtrlSetState(-1, $GUI_DISABLE + $GUI_HIDE )

GUISetState(@SW_SHOW)


$guiimages[0][0]=$ComputationACTIVE
$guiimages[1][0]=$AquisitionACTIVE
$guiimages[2][0]=$ApplicationACTIVE
$guiimages[3][0]=$AdjustementACTIVE
$guiimages[4][0]=$ConnectionACTIVE
$guiimages[5][0]=$ImprimantesACTIVE
$guiimages[6][0]=$ExecutionACTIVE
$guiimages[0][1]=$ComputationOK
$guiimages[1][1]=$AquisitionOK
$guiimages[2][1]=$ApplicationOK
$guiimages[3][1]=$AdjustementOK
$guiimages[4][1]=$ConnectionOK
$guiimages[5][1]=$ImprimantesOK
$guiimages[6][1]=$ExecutionOK
$guiimages[0][2]=$Computationerror
$guiimages[1][2]=$Aquisitionerror
$guiimages[2][2]=$Applicationerror
$guiimages[3][2]=$AdjustementERROR
$guiimages[4][2]=$Connectionerror
$guiimages[5][2]=$ImprimantesERROR
$guiimages[6][2]=$Executionerror




;While 1
    For $x = 0 To 2 
        For $y = 0 To 6
        ;GUICtrlSetState($guiimages[$y][$x],$GUI_SHOW)
            ControlShow("GreenScript v2.0a","",$guiimages[$y][$x])
            Sleep(1000)
            ControlHide("GreenScript v2.0a","",$guiimages[$y][$x])
        ;GUICtrlSetState($guiimages[$y][$x],$GUI_HIDE )
        next
    Next
;WEnd


;~ While 1
;~  $msg = GuiGetMsg()
;~  Select
;~  Case $msg = $GUI_EVENT_CLOSE
;~      ExitLoop
;~  Case Else
;~  ;;;;;;;
;~  EndSelect
;~ WEnd
Exit

GreenseedMCSE+I, CCNA, A+Canada, QuebecMake Love Around You.

Link to comment
Share on other sites

Hi! thx for the idea it a nice idea but im not sure about the effect i have put this in the code

...ect...
$MainGUI = GUICreate("GreenScript v2.0a", 640, 504, 197, 122, $DS_SETFOREGROUND, BitOR($WS_EX_TOOLWINDOW,$WS_EX_TOPMOST,$WS_EX_CLIENTEDGE))
GUISetCursor (7)
$BackGroundIMG = GUICtrlCreatePic($imagespath&"MainGUI.jpg", 0, 0, 640, 480)
GUICtrlSetCursor ($BackGroundIMG, 7)
GUISetState(@SW_LOCK)
$Computationerror = GUICtrlCreatePic($imagespath&"Button\Computationerror_303x55 copy.jpg", 0, 14, 303, 55)
GUICtrlSetState(-1, $GUI_HIDE )
$Aquisitionerror = GUICtrlCreatePic($imagespath&"Button\Aquisitionerror_280x49 copy.jpg", 0, 81, 280, 49)..ect...

the idea it to lock the background! if im right!

i think this function work only for the guicreate() and not the control creation! not sure

no improuvement! :o

anyway thanks B)

Edited by Greenseed

GreenseedMCSE+I, CCNA, A+Canada, QuebecMake Love Around You.

Link to comment
Share on other sites

This is the updated code! like you suggest and it do nothing!

#include <guiconstants.au3>
Opt("CaretCoordMode", 1)      ;1=absolute, 0=relative
Opt("ExpandEnvStrings", 0)    ;0=don't expand, 1=do expand
Opt("MouseClickDelay", 10)    ;10 milliseconds
Opt("MouseClickDownDelay", 10);10 milliseconds
Opt("MustDeclareVars", 0)      ;0=no, 1=require pre-declare
Opt("PixelCoordMode", 1)      ;1=absolute, 0=relative
Opt("RunErrorsFatal", 0)      ;1=fatal, 0=silent set @error
Opt("SendAttachMode", 0)      ;0=don't attach, 1=do attach
Opt("SendCapslockMode", 1)    ;1=store and restore, 0=don't
Opt("SendKeyDelay", 8)        ;5 milliseconds
Opt("SendKeyDownDelay", 1)    ;1 millisecond
Opt("TrayIconDebug", 1)        ;0=no info, 1=debug line info
Opt("TrayIconHide", 0)        ;0=show, 1=hide tray icon
Opt("WinWaitDelay", 250)      ;250 milliseconds
Opt("WinDetectHiddenText", 0)  ;0=don't detect, 1=do detect
Opt("WinSearchChildren", 1)    ;0=no, 1=search children also
Opt("WintitleMatchMode", 1)    ;1=start, 2=subStr, 3=exact, 4=...
Opt("ColorMode", 0)

$imagespath = @ScriptDir&"\Images\"
Dim $guiimages[7][3]



$MainGUI = GUICreate("GreenScript v2.0a", 640, 504, 197, 122, $DS_SETFOREGROUND, BitOR($WS_EX_TOOLWINDOW,$WS_EX_TOPMOST,$WS_EX_CLIENTEDGE))
GUISetCursor (7)
$BackGroundIMG = GUICtrlCreatePic($imagespath&"MainGUI.jpg", 0, 0, 640, 480)
GUICtrlSetCursor ($BackGroundIMG, 7)
GUISetState(@SW_LOCK)
$Computationerror = GUICtrlCreatePic($imagespath&"Button\Computationerror_303x55 copy.jpg", 0, 14, 303, 55)
GuiSetState(@SW_UNLOCK)
$Aquisitionerror = GUICtrlCreatePic($imagespath&"Button\Aquisitionerror_280x49 copy.jpg", 0, 81, 280, 49)
GuiSetState(@SW_UNLOCK)
$Applicationerror = GUICtrlCreatePic($imagespath&"Button\Applicationerror_303x49 copy.jpg", 0, 142, 303, 49)
GuiSetState(@SW_UNLOCK)
$AdjustementERROR = GUICtrlCreatePic($imagespath&"Button\AdjustementERROR_310x49 copy.jpg", 0, 214, 310, 49)
GuiSetState(@SW_UNLOCK)
$Connectionerror = GUICtrlCreatePic($imagespath&"Button\Connectionerror_283x49 copy.jpg", 0, 279, 283, 49)
GuiSetState(@SW_UNLOCK)
$ImprimantesERROR = GUICtrlCreatePic($imagespath&"Button\ImprimantesERROR_335x49 copy.jpg", 0, 340, 335, 49)
GuiSetState(@SW_UNLOCK)
$Executionerror = GUICtrlCreatePic($imagespath&"Button\Executionerror_365x49 copy.jpg", 0, 406, 365, 49)
GuiSetState(@SW_UNLOCK)
$ExecutionOK = GUICtrlCreatePic($imagespath&"Button\ExecutionOK_363x52 copy.jpg", 0, 405, 363, 52)
GuiSetState(@SW_UNLOCK)
$ImprimantesOK = GUICtrlCreatePic($imagespath&"Button\ImprimantesOK_343x52 copy.jpg", 0, 341, 343, 52)
GuiSetState(@SW_UNLOCK)
$ConnectionOK = GUICtrlCreatePic($imagespath&"Button\ConnectionOK_287x52 copy.jpg", 0, 276, 287, 52)
GuiSetState(@SW_UNLOCK)
$AdjustementOK = GUICtrlCreatePic($imagespath&"Button\AdjustementOK_303x52 copy.jpg", 0, 214, 303, 52)
GuiSetState(@SW_UNLOCK)
$ApplicationOK = GUICtrlCreatePic($imagespath&"Button\ApplicationOK_303x52 copy.jpg", 0, 142, 303, 52)
GuiSetState(@SW_UNLOCK)
$AquisitionOK = GUICtrlCreatePic($imagespath&"Button\AquisitionOK_269x52 copy.jpg", 0, 79, 269, 52)
GuiSetState(@SW_UNLOCK)
$ComputationOK = GUICtrlCreatePic($imagespath&"Button\ComputationOK_278x52 copy.jpg", 0, 17, 278, 52)
GuiSetState(@SW_UNLOCK)
$ComputationACTIVE = GUICtrlCreatePic($imagespath&"Button\ComputationACTIVE_281x55 copy.jpg", 0, 17, 281, 55)
GuiSetState(@SW_UNLOCK)
$AquisitionACTIVE = GUICtrlCreatePic($imagespath&"Button\AquisitionACTIVE_280x49.jpg", 0, 84, 280, 49)
GuiSetState(@SW_UNLOCK)
$ApplicationACTIVE = GUICtrlCreatePic($imagespath&"Button\ApplicationACTIVE_298x52 copy.jpg", 0, 145, 298, 52)
GuiSetState(@SW_UNLOCK)
$AdjustementACTIVE = GUICtrlCreatePic($imagespath&"Button\AdjustementACTIVE_304x52 copy.jpg", 0, 217, 304, 52)
GuiSetState(@SW_UNLOCK)
$ConnectionACTIVE = GUICtrlCreatePic($imagespath&"Button\ConnectionACTIVE_282x52 copy.jpg", 0, 279, 282, 52)
GuiSetState(@SW_UNLOCK)
$ImprimantesACTIVE = GUICtrlCreatePic($imagespath&"Button\ImprimantesACTIVE_336x52 copy.jpg", 0, 342, 336, 52)
GuiSetState(@SW_UNLOCK)
$ExecutionACTIVE = GUICtrlCreatePic($imagespath&"Button\ExecutionACTIVE_358x52 copy.jpg", 0, 404, 358, 52)
GuiSetState(@SW_UNLOCK)
$ButtonDOWN = GUICtrlCreatePic($imagespath&"Button\ButtonDOWN_60x48 copy.jpg", 574, 275, 60, 48)
GuiSetState(@SW_UNLOCK)

GUISetState()

$guiimages[0][0]=$ComputationACTIVE
$guiimages[1][0]=$AquisitionACTIVE
$guiimages[2][0]=$ApplicationACTIVE
$guiimages[3][0]=$AdjustementACTIVE
$guiimages[4][0]=$ConnectionACTIVE
$guiimages[5][0]=$ImprimantesACTIVE
$guiimages[6][0]=$ExecutionACTIVE
$guiimages[0][1]=$ComputationOK
$guiimages[1][1]=$AquisitionOK
$guiimages[2][1]=$ApplicationOK
$guiimages[3][1]=$AdjustementOK
$guiimages[4][1]=$ConnectionOK
$guiimages[5][1]=$ImprimantesOK
$guiimages[6][1]=$ExecutionOK
$guiimages[0][2]=$Computationerror
$guiimages[1][2]=$Aquisitionerror
$guiimages[2][2]=$Applicationerror
$guiimages[3][2]=$AdjustementERROR
$guiimages[4][2]=$Connectionerror
$guiimages[5][2]=$ImprimantesERROR
$guiimages[6][2]=$Executionerror



;~ sleep(3000)
;~ GUICtrlSetImage ( $Applicationerror, $imagespath&"Button\Applicationerror_303x49 copy.jpg")
;~ GUICtrlSetState($Applicationerror,$GUI_SHOW)
;~ sleep(3000)
;~ GUICtrlSetImage ( $Applicationerror, "")

;While 1
    For $x = 0 To 2 
        For $y = 0 To 6
        ;GUICtrlSetImage ( $guiimages[$y][$x], "")
        ;ControlShow("GreenScript v2.0a","",$guiimages[$y][$x])
            GUISetState(@SW_LOCK,$guiimages[$y][$x])
            Sleep(60)
            GUISetState(@SW_UNLOCK,$guiimages[$y][$x])
            sleep(60)
        ;GUICtrlSetState($guiimages[$y][$x],$GUI_DISABLE + $GUI_HIDE )
        ;ControlHide("GreenScript v2.0a","",$guiimages[$y][$x])
        next
    Next
;WEnd

;~ While 1
;~     $msg = GuiGetMsg()
;~     Select
;~     Case $msg = $GUI_EVENT_CLOSE
;~         ExitLoop
;~     Case Else
;~     ;;;;;;;
;~     EndSelect
;~ WEnd
Exit

i have tried difference manner! wint lock or unlocking the main gui or the main picture nothing append! i tried both way

with initiated lock or unlock.

Edited by Greenseed

GreenseedMCSE+I, CCNA, A+Canada, QuebecMake Love Around You.

Link to comment
Share on other sites

@sw_lock apply to a winhandle in your case $MainGUI.

I don't think it will be the solution.

I don't if there is one as each time you will update a control the window will be refresh and can flicker.

@sw_lock will allow to update several and have only one flicker.

The GUI functions are basic Windows wrapper and so you cannot expect to replicate some other control which work more efficiently with the screen.

Link to comment
Share on other sites

do you think if i do a api call with DllCall() to User32.dll,RedrawWindows and the User32.dll,RECTANGLE it will be better or autoit do exactely same thing!

i've tryed with SW_EX_LAYERED style! and it flicker + i got some white dot!

maybe i will simply do a gui like we! know!

maybe i can try with implement a OBJECT from i dunnot know, to do what i wan!

have you tried the script? and if yes do you see the flicker?

this is the last code! but with any methode i got flicker not always same amount, with differente technique!

this one is the fastes with the less flicker!

#include <guiconstants.au3>
Opt("CaretCoordMode", 1)       ;1=absolute, 0=relative
Opt("ExpandEnvStrings", 0)   ;0=don't expand, 1=do expand
Opt("MouseClickDelay", 10)   ;10 milliseconds
Opt("MouseClickDownDelay", 10) ;10 milliseconds
Opt("MustDeclareVars", 0)     ;0=no, 1=require pre-declare
Opt("PixelCoordMode", 1)       ;1=absolute, 0=relative
Opt("RunErrorsFatal", 0)       ;1=fatal, 0=silent set @error
Opt("SendAttachMode", 0)       ;0=don't attach, 1=do attach
Opt("SendCapslockMode", 1)   ;1=store and restore, 0=don't
Opt("SendKeyDelay", 8)       ;5 milliseconds
Opt("SendKeyDownDelay", 1)   ;1 millisecond
Opt("TrayIconDebug", 1)     ;0=no info, 1=debug line info
Opt("TrayIconHide", 0)       ;0=show, 1=hide tray icon
Opt("WinWaitDelay", 250)       ;250 milliseconds
Opt("WinDetectHiddenText", 0)  ;0=don't detect, 1=do detect
Opt("WinSearchChildren", 1) ;0=no, 1=search children also
Opt("WintitleMatchMode", 1) ;1=start, 2=subStr, 3=exact, 4=...
Opt("ColorMode", 0)

$imagespath = @ScriptDir&"\Images\"
Dim $guiimages[7][3]



$MainGUI = GUICreate("GreenScript v2.0a", 640, 504, 197, 122, $DS_SETFOREGROUND, $WS_EX_TOOLWINDOW+$WS_EX_TOPMOST)
GUISetCursor (7)
GUISetState(@SW_LOCK)




$ButtonDOWN = GUICtrlCreatePic($imagespath&"Button\ButtonDOWN_60x48 copy.jpg", 574, 275, 60, 48)
GuiCtrlSetState(-1,$GUI_HIDE)
GUISetState()
$BackGroundIMG = GUICtrlCreatePic($imagespath&"MainGUI.jpg", 0, 0, 640, 480)
GUICtrlSetCursor ($BackGroundIMG, 7)
GuiCtrlSetState(-1,$GUI_SHOW)

$ComputationACTIVE = GUICtrlCreatePic($imagespath&"Button\ComputationACTIVE_281x55 copy.jpg", 0, 17, 281, 55)
GuiCtrlSetState(-1,$GUI_HIDE)
$AquisitionACTIVE = GUICtrlCreatePic($imagespath&"Button\AquisitionACTIVE_280x49.jpg", 0, 84, 280, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$ApplicationACTIVE = GUICtrlCreatePic($imagespath&"Button\ApplicationACTIVE_298x52 copy.jpg", 0, 145, 298, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$AdjustementACTIVE = GUICtrlCreatePic($imagespath&"Button\AdjustementACTIVE_304x52 copy.jpg", 0, 217, 304, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ConnectionACTIVE = GUICtrlCreatePic($imagespath&"Button\ConnectionACTIVE_282x52 copy.jpg", 0, 279, 282, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ImprimantesACTIVE = GUICtrlCreatePic($imagespath&"Button\ImprimantesACTIVE_336x52 copy.jpg", 0, 342, 336, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ExecutionACTIVE = GUICtrlCreatePic($imagespath&"Button\ExecutionACTIVE_358x52 copy.jpg", 0, 404, 358, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ExecutionOK = GUICtrlCreatePic($imagespath&"Button\ExecutionOK_363x52 copy.jpg", 0, 405, 363, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
;GUICtrlSetStyle(-1,$WS_VISIBLE,$WS_EX_TOPMOST)
$ImprimantesOK = GUICtrlCreatePic($imagespath&"Button\ImprimantesOK_343x52 copy.jpg", 0, 341, 343, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ConnectionOK = GUICtrlCreatePic($imagespath&"Button\ConnectionOK_287x52 copy.jpg", 0, 276, 287, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$AdjustementOK = GUICtrlCreatePic($imagespath&"Button\AdjustementOK_303x52 copy.jpg", 0, 214, 303, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ApplicationOK = GUICtrlCreatePic($imagespath&"Button\ApplicationOK_303x52 copy.jpg", 0, 142, 303, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$AquisitionOK = GUICtrlCreatePic($imagespath&"Button\AquisitionOK_269x52 copy.jpg", 0, 79, 269, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$ComputationOK = GUICtrlCreatePic($imagespath&"Button\ComputationOK_278x52 copy.jpg", 0, 17, 278, 52)
GuiCtrlSetState(-1,$GUI_HIDE)
$Computationerror = GUICtrlCreatePic($imagespath&"Button\Computationerror_303x55 copy.jpg", 0, 14, 303, 55)
GuiCtrlSetState(-1,$GUI_HIDE)
$Aquisitionerror = GUICtrlCreatePic($imagespath&"Button\Aquisitionerror_280x49 copy.jpg", 0, 81, 280, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$Applicationerror = GUICtrlCreatePic($imagespath&"Button\Applicationerror_303x49 copy.jpg", 0, 142, 303, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$AdjustementERROR = GUICtrlCreatePic($imagespath&"Button\AdjustementERROR_310x49 copy.jpg", 0, 214, 310, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$Connectionerror = GUICtrlCreatePic($imagespath&"Button\Connectionerror_283x49 copy.jpg", 0, 279, 283, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$ImprimantesERROR = GUICtrlCreatePic($imagespath&"Button\ImprimantesERROR_335x49 copy.jpg", 0, 340, 335, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$Executionerror = GUICtrlCreatePic($imagespath&"Button\Executionerror_365x49 copy.jpg", 0, 406, 365, 49)
GuiCtrlSetState(-1,$GUI_HIDE)
$guiimages[0][0]=$ComputationACTIVE
$guiimages[1][0]=$AquisitionACTIVE
$guiimages[2][0]=$ApplicationACTIVE
$guiimages[3][0]=$AdjustementACTIVE
$guiimages[4][0]=$ConnectionACTIVE
$guiimages[5][0]=$ImprimantesACTIVE
$guiimages[6][0]=$ExecutionACTIVE
$guiimages[0][1]=$ComputationOK
$guiimages[1][1]=$AquisitionOK
$guiimages[2][1]=$ApplicationOK
$guiimages[3][1]=$AdjustementOK
$guiimages[4][1]=$ConnectionOK
$guiimages[5][1]=$ImprimantesOK
$guiimages[6][1]=$ExecutionOK
$guiimages[0][2]=$Computationerror
$guiimages[1][2]=$Aquisitionerror
$guiimages[2][2]=$Applicationerror
$guiimages[3][2]=$AdjustementERROR
$guiimages[4][2]=$Connectionerror
$guiimages[5][2]=$ImprimantesERROR
$guiimages[6][2]=$Executionerror



;~ sleep(3000)
;~ GUICtrlSetImage ( $Applicationerror, $imagespath&"Button\Applicationerror_303x49 copy.jpg")
;~ GUICtrlSetState($Applicationerror,$GUI_SHOW)
;~ sleep(3000)
;~ GUICtrlSetImage ( $Applicationerror, "")

;While 1
    For $x = 0 To 2 
        For $y = 0 To 6
        ;GUICtrlSetImage ( $guiimages[$y][$x], "")
            ControlShow("GreenScript v2.0a","",$guiimages[$y][$x])
        ;GUISetState(@SW_UNLOCK,$guiimages[$y][$x])
            Sleep(1000)
        ;GUISetState(@SW_LOCK,$guiimages[$y][$x])
            
        ;GUICtrlSetState($guiimages[$y][$x],$GUI_DISABLE + $GUI_HIDE )
            ControlHide("GreenScript v2.0a","",$guiimages[$y][$x])
            sleep(1000)
        next
    Next
;WEnd

;~ While 1
;~  $msg = GuiGetMsg()
;~  Select
;~  Case $msg = $GUI_EVENT_CLOSE
;~      ExitLoop
;~  Case Else
;~  ;;;;;;;
;~  EndSelect
;~ WEnd
Exit

check the attachement in the first post for the file!

GreenseedMCSE+I, CCNA, A+Canada, QuebecMake Love Around You.

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...