dantay9 Posted March 28, 2009 Share Posted March 28, 2009 I am trying to make a progress bar with a label in the middle of it, but when the progress bar refreshes, the label is hidden. Is there a way to make the label always on top of the progress bar? $GUI = GUICreate("Downloading Foxit", 295, 61, 332, 223) $Progress = GUICtrlCreateProgress(8, 32, 275, 20) GUICtrlCreateLabel("Please Wait...", 8, 8, 275, 20, 1); SS_CENTER GUICtrlSetFont(-1, 10, 400, 0, "Arial") $Percent = GUICtrlCreateLabel("", 8, 32, 275, 20, 1); SS_CENTER GUICtrlSetBkColor(-1, -2); GUI_BKCOLOR_TRANSPARENT GUICtrlSetFont(-1, 10, 400, 0, "Arial") GUICtrlSetState(-1, 2048); GUI_ONTOP GUISetState(@SW_SHOW) $Size = InetGetSize("http://foxit.vo.llnwd.net/o28/pub/foxit/reader/desktop/win/3.x/3.0/enu/FoxitReader30_enu_Setup.exe") InetGet("http://foxit.vo.llnwd.net/o28/pub/foxit/reader/desktop/win/3.x/3.0/enu/FoxitReader30_enu_Setup.exe", @DesktopDir & "\Foxit.exe", 1, 1) While @InetGetActive If GUICtrlRead($Percent) <> Ceiling(@InetGetBytesRead / $Size * 100) Then GUICtrlSetData($Percent, Ceiling(@InetGetBytesRead / $Size * 100) & '%') EndIf If GUICtrlRead($Progress) <> Ceiling(@InetGetBytesRead / $Size * 100) Then GUICtrlSetData($Progress, Ceiling(@InetGetBytesRead / $Size * 100)) EndIf Sleep(100) WEnd Link to comment Share on other sites More sharing options...
BinaryBrother Posted March 28, 2009 Share Posted March 28, 2009 You could put the label in the loop, but that would cause some flicker... There is a better 'Progress UDF' around here somewhere... SIGNATURE_0X800007D NOT FOUND Link to comment Share on other sites More sharing options...
GEOSoft Posted March 28, 2009 Share Posted March 28, 2009 Have you tried setting the extended style for the label to $WS_EX_TOPMOST George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
dantay9 Posted March 28, 2009 Author Share Posted March 28, 2009 $WS_EX_TOPMOST doesn't work. I found a really good udf though. It is from the german forum by progandy.http://progandy.pr.funpic.de/index.php/com.../id,17/lang,de/ Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now