jWalker Posted March 4, 2012 Posted March 4, 2012 Hey i am tryin to run 7zip with parameters. I could use the ShellExecute function but it doesn't return the PID. I need the PID to look if its finished... Run returns the PID but i think i can't use any parameters with it?! Any solutions?
Developers Jos Posted March 4, 2012 Developers Posted March 4, 2012 You can use parameters with it ... have you tried? Jos 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.
jWalker Posted March 4, 2012 Author Posted March 4, 2012 And where? Run ( "program" [, "workingdir" [, show_flag [, opt_flag]]] )
Developers Jos Posted March 4, 2012 Developers Posted March 4, 2012 (edited) Just on the commandline as you usually would do: Run("Notepad.exe test.txt") .. and when doublequoting is required due to spaces in the path just do something like: Run('"Notepad.exe" "test.txt"') Jos Edited March 4, 2012 by Jos 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.
jWalker Posted March 4, 2012 Author Posted March 4, 2012 (edited) $BACKUP = Run('"C:Program Files7-Zip7za.exe" "a C:UsersDannyAppDataRoaming.minecraftmcserverbackup"' & @YEAR & "-" & @MON & "-" & "--" & @MDAY & "-" & @HOUR & "-" & @MIN & "-" & @SEC & '"backup.7z C:UsersDannyAppDataRoaming.minecraftmcserversurvival"', "", "", @SW_HIDE)Y U NO WORK?y u no work madam? Edited March 4, 2012 by jWalker
KaFu Posted March 4, 2012 Posted March 4, 2012 USING CAPITAL LETTERS IS CONSIDERED RUDE BEHAVIOR.... $BACKUP = Run('"C:Program Files7-Zip7za.exe" a "C:UsersDannyAppDataRoaming.minecraftmcserverbackup' & @YEAR & '-' & @MON & '-' & '--' & @MDAY & '-' & @HOUR & '-' & @MIN & '-' & @SEC & 'backup.7z" "C:UsersDannyAppDataRoaming.minecraftmcserversurvival"', "", "", @SW_HIDE) OS: Win10-22H2 - 64bit - German, AutoIt Version: 3.3.16.1, AutoIt Editor: SciTE, Website: https://funk.eu AMT - Auto-Movie-Thumbnailer (2024-Oct-13) BIC - Batch-Image-Cropper (2023-Apr-01) COP - Color Picker (2009-May-21) DCS - Dynamic Cursor Selector (2024-Oct-13) HMW - Hide my Windows (2024-Oct-19) HRC - HotKey Resolution Changer (2012-May-16) ICU - Icon Configuration Utility (2018-Sep-16) SMF - Search my Files (2024-Oct-20) - THE file info and duplicates search tool SSD - Set Sound Device (2017-Sep-16)
Developers Jos Posted March 4, 2012 Developers Posted March 4, 2012 (edited) Your quoting doesn't look correct and your parameters neither. maybe: $BACKUP = Run('"C:Program Files7-Zip7za.exe" a "C:UsersDannyAppDataRoaming.minecraftmcserverbackup' & @YEAR & "-" & @MON & "-" & "--" & @MDAY & "-" & @HOUR & "-" & @MIN & "-" & @SEC & 'backup.7z" "C:UsersDannyAppDataRoaming.minecraftmcserversurvival"', "C:Program Files7-Zip", @SW_HIDE) ...else show the commandline as it should look ... and would appreciate when you use normal English. Edited March 4, 2012 by Jos 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.
MPHillier Posted March 4, 2012 Posted March 4, 2012 I agree w\ Jos - quoting and parameters don't look correct. Check out Help file - Language Reference - Strings. I Break and Fix things... If the surf is up I'm outta here.....
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