bobheart 0 Posted May 27, 2004 I can't seem to get the bar to work with the backup or restore . expandcollapse popup;Generated with AutoBuilder 0.3 Opt("GUICoordMode", 1) Opt("GUINotifyMode", 1) GuiCreate("Do a backup", 243,201,10,10,0x04CF0000) $pic_1 = GUISetControl("pic", "earth_bca3.gif", 20,20, 70,70) $button_1 = GUISetControl("button", "Backup", 130,20, 90,30) $button_2 = GUISetControl("button", "Restore", 130,80, 90,30) $button_3 = GUISetControl("button", "Help", 130,140, 90,30) GuiShow() While 1 sleep(100) $msg = GuiMsg(0) Select Case $msg = -3 Exit Case $msg = $pic_1 ;;; Case $msg = $button_1 DirCreate("C:\VAULT") ProgressOn("Progress Meter", "Now making your backup", "0 percent") For $i = 10 to 100 step 10 sleep(1000) ProgressSet( $i, $i & " percent") Next ProgressSet(100 , "Done", "Complete") sleep(500) ProgressOff() Run("backup.bat", "", @SW_MINIMIZE ) ;;; Case $msg = $button_2 ProgressOn("Progress Meter", "Now restoring your backup", "0 percent") For $i = 10 to 100 step 10 sleep(1000) ProgressSet( $i, $i & " percent") Next ProgressSet(100 , "Done", "Complete") sleep(500) ProgressOff() Run("restore.bat", "", @SW_MINIMIZE ) ;;; Case $msg = $button_3 ;;; EndSelect WEnd Exit Share this post Link to post Share on other sites
Marc 36 Posted May 27, 2004 Using the current unstable 3.102, it works... 10,20,...done. It's my job to comfort the disturbed and to disturb the comfortable. My Projects: Profiler, MakeSFX, UserInfo, Simple Robocopy Progressbar Share this post Link to post Share on other sites
bobheart 0 Posted May 27, 2004 it runs bu it is running by its self not with the program .. Share this post Link to post Share on other sites
Marc 36 Posted May 27, 2004 Oh, I see Well, currently your script loops the progressbar up to 100%, sets the text to done and after that it invokes the according batch file. Shouldn't you first invoke the batch and then do the progress bar? It's my job to comfort the disturbed and to disturb the comfortable. My Projects: Profiler, MakeSFX, UserInfo, Simple Robocopy Progressbar Share this post Link to post Share on other sites
bobheart 0 Posted May 27, 2004 heh heh thats what I need help with .. Share this post Link to post Share on other sites
bobheart 0 Posted May 27, 2004 Bump dee bump bump dee bump . Share this post Link to post Share on other sites
SlimShady 1 Posted May 27, 2004 (edited) This is all I can make of it. I don't have another solution. expandcollapse popup;Generated with AutoBuilder 0.3 Opt("GUICoordMode", 1) Opt("GUINotifyMode", 1) GuiCreate("Do a backup", 243,201,10,10,0x04CF0000) $pic_1 = GUISetControl("pic", "earth_bca3.gif", 20,20, 70,70) $button_1 = GUISetControl("button", "Backup", 130,20, 90,30) $button_2 = GUISetControl("button", "Restore", 130,80, 90,30) $button_3 = GUISetControl("button", "Help", 130,140, 90,30) GuiShow() While 1 sleep(100) $msg = GuiMsg(0) Select Case $msg = -3 Exit Case $msg = $pic_1 ;;; Case $msg = $button_1 DirCreate("C:\VAULT") ProgressOn("Progress Meter", "Now making your backup", "0 percent") Run("backup.bat", "", @SW_MINIMIZE ) For $i = 10 to 100 step 10 sleep(1000) ProgressSet( $i, $i & " percent") Next ProgressSet(100 , "Done", "Complete") sleep(500) ProgressOff() ;;; Case $msg = $button_2 ProgressOn("Progress Meter", "Now restoring your backup", "0 percent") Run("restore.bat", "", @SW_MINIMIZE ) For $i = 10 to 100 step 10 sleep(1000) ProgressSet( $i, $i & " percent") Next ProgressSet(100 , "Done", "Complete") sleep(500) ProgressOff() ;;; Case $msg = $button_3 ;;; EndSelect WEnd Exit Edited May 27, 2004 by SlimShady Share this post Link to post Share on other sites
bobheart 0 Posted May 27, 2004 Thank you for the help .. that seems to work . Share this post Link to post Share on other sites