Borje Posted August 18, 2007 Share Posted August 18, 2007 Is it any body that can help me what command I must use to have a bigger progress window is it possible to change the size ? Please some example Link to comment Share on other sites More sharing options...
Zedna Posted August 18, 2007 Share Posted August 18, 2007 Instead of ProgressOn() make your own GUI with progressbar. Look at GUICreate() and GUICtrlCreateProgress() in Autoit helpfile. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Borje Posted August 18, 2007 Author Share Posted August 18, 2007 Thanks Zedna but I am very newbee in this can you give some example Link to comment Share on other sites More sharing options...
Zedna Posted August 18, 2007 Share Posted August 18, 2007 Thanks Zedna but I am very newbee in this can you give some exampleLook at Koda - Autoit GUI editorand also read Autoit helpfile, there is a lot of nice examples. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Zedna Posted August 18, 2007 Share Posted August 18, 2007 Here is example: #include <GUIConstants.au3> GUICreate(StringTrimRight(@ScriptName,4),220,100, -1,-1, $WS_CAPTION, $WS_EX_TOPMOST) ;GUICreate(StringTrimRight(@ScriptName,4),220,100, -1,-1, $WS_MINIMIZEBOX + $WS_GROUP + $WS_CAPTION + $WS_POPUP + $WS_SYSMENU, $WS_EX_TOPMOST) ;GUICreate(StringTrimRight(@ScriptName,4),220,100, -1,-1, -1, $WS_EX_TOPMOST) ;GUISetBkColor (0xE0FFFF) $progressbar = GUICtrlCreateProgress (10,15,200,20,$PBS_SMOOTH) $procent = GUICtrlCreateLabel ('0 %', 10,40,200,20,$SS_CENTER) $stop = GUICtrlCreateButton ("Stop",75,68,70,22,$BS_DEFPUSHBUTTON) GUISetState() $i = 0 While 1 $msg = GUIGetMsg() If $msg = $stop OR $msg = $GUI_EVENT_CLOSE Then ExitLoop $i = $i + 1 If $i > 100 Then $i = 0 GUICtrlSetData ($progressbar,$i) GUICtrlSetData ($procent,$i & ' %') Sleep(100) Wend Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
Achilles Posted August 18, 2007 Share Posted August 18, 2007 (edited) GuiCreate('Progress', 500, 110);Make a window that is 500 pixels by 110 pixels $label = GuiCtrlCreateLabel('Testing progress bar...', 10, 10, 200, 20);Create a simple label $progress = GuiCtrlCreateProgress(100, 30, 300, 30) $btnTestProgress = GuiCtrlCreateButton('Test Progress', 200, 70, 100, 30) GuiSetState();Show the GUI that we have created While 1 Switch GuiGetMsg() Case -3;If exit was clicked Exit Case $btnTestProgress;If the button was pressed GuiCtrlSetData($label, 'Starting progress...');Set the data of the label For $a = 1 to 100;Loop 100 times GuiCtrlSetData($progress, $a);Set the data with the current value of $a Sleep(15);Sleep a little bit so the user can see the progress go up If $a = 50 then GuiCtrlSetData($label, 'Half way done...');Set the label at half way done Next GuiCtrlSetData($label, 'All done') EndSwitch WEnd Edited August 18, 2007 by Piano_Man My Programs[list][*]Knight Media Player[*]Multiple Desktops[*]Daily Comics[*]Journal[/list] Link to comment Share on other sites More sharing options...
Borje Posted August 19, 2007 Author Share Posted August 19, 2007 Thank you all for the examples I try this 2 examples thanks again..... 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