Jump to content

Recommended Posts

Posted

hello@community,

i am new @ autoit. i want to rar some directories. my command is:

Run ("C:\Program Files\WinRAR\Rar.exe a -m0 -v500000k M:\TEMPRAR\"&$rarName&" M:\Mix\"&$dirName&"\*.*")

I got an error, cause rar.exe has problems with the directoryname, the spaces or the variable. the variable "$dirName" is something like M:\Mix\DJ Tiesto 2016 Mix\

I think the problem is, how to set the quotes. i believe i tried all possibilities with no success. 

 

some ideas how to set quotes??

  • Developers
Posted

Something like this maybe?:

Run ('C:\Program Files\WinRAR\Rar.exe a -m0 -v500000k "M:\TEMPRAR\' & $rarName & '" "M:\Mix\' & $dirName & '\*.*"')

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.
  :)

  • Moderators
Posted

@noobee88 I always suggest, when working with spaces and quotes, do write it out to the console first and then try it at the command line. So does this output:

ConsoleWrite("C:\Program Files\WinRAR\Rar.exe a -m0 -v500000k M:\TEMPRAR\" & $rarName & " M:\Mix\" & $dirName & "\*.*" & @CRLF)

copied into a command line window, give you what you want?

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...