duhu Posted August 9, 2005 Share Posted August 9, 2005 Hy...i'm calling a batch script that defragments the hdd trough the command: RunWait(@ComSpec & " /c " & 'start data\Def.vbs', "", @SW_HIDE) the prblem is that i tried to hide the window that appear when the batch starts defrgamenting the hdd but its not working (the name of the window is 'C:\Windows\system32\Defrag.exe", its not working with any commands like WinSetState or others, i even tried to put into the title of window "classname=WindowsCommandsConsole" (i saw that in Window Info) but its not working. Anyone know why Pls help thx Srry for my eng if its bad Doohoodogg Link to comment Share on other sites More sharing options...
Developers Jos Posted August 9, 2005 Developers Share Posted August 9, 2005 Hy...i'm calling a batch script that defragments the hdd trough the command: RunWait(@ComSpec & " /c " & 'start data\Def.vbs', "", @SW_HIDE) the prblem is that i tried to hide the window that appear when the batch starts defrgamenting the hdd but its not working (the name of the window is 'C:\Windows\system32\Defrag.exe", its not working with any commands like WinSetState or others, i even tried to put into the title of window "classname=WindowsCommandsConsole" (i saw that in Window Info) but its not working. Anyone know whyPls helpthxSrry for my eng if its badDoohoodogg<{POST_SNAPBACK}>Did you change the RunWait() to Run() ? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Danny35d Posted August 9, 2005 Share Posted August 9, 2005 (edited) The problem is that Def.vbs has his own RUN and that open a window with Defrag.exe.I'm asuming that the vbs script has a line like this.Set WshShell = WScript.CreateObject("WScript.Shell")Return = WshShell.Run("defrag " & d & " -f", 1, TRUE)change 1 to 0 so the script will run defrag hidenSorry for my spelling but, english is my second languageHope this help!!! Edited August 9, 2005 by Danny35d AutoIt Scripts:NetPrinter - Network Printer UtilityRobocopyGUI - GUI interface for M$ robocopy command line Link to comment Share on other sites More sharing options...
duhu Posted August 10, 2005 Author Share Posted August 10, 2005 Thx a lot, that worked. Doohoodogg 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