Muzzikap Posted August 12, 2005 Share Posted August 12, 2005 I'm playing a bit with autoit. and I'm trying to mount an image in daemon tools using the command line. Daemon tools help file: -unmount allows unmounting images from command line. Syntax is: -unmount <n> where 'n' means DVD-ROM device number ('0' - '3' allowed) When i try to run the line shown below i get the following error returned Het systeem kan het opgegeven pad niet vinden. >> simple translated by me>> System cannot find given path RunWait(@comspec & '/k c:\Program Files\D-Tools\daemon.exe -demount 1') I guess that the "/k" that i'm using is wrong. I without it an cmd-window is opened and nothing else happens. I hope somebody can tell me what I'm doing wrong and where the /k stands for (perhaps a link with info) tnxz Link to comment Share on other sites More sharing options...
Muzzikap Posted August 12, 2005 Author Share Posted August 12, 2005 (edited) Found the problem. Solved it using the following code that i found on this forum: $pathToDaemonTools = "c:\Program Files\D-Tools\daemon.exe" $pathToIso = $aImLijst[1] RunWait ( $pathToDaemonTools & ' -unmount 1' ) RunWait ( $pathToDaemonTools & ' -mount 1, "' & $pathToIso & '"' ) Edited August 12, 2005 by Muzzikap Link to comment Share on other sites More sharing options...
seandisanti Posted August 12, 2005 Share Posted August 12, 2005 Found the problem. Solved it using the following code that i found on this forum:$pathToDaemonTools = "c:\Program Files\D-Tools\daemon.exe" $pathToIso = $aImLijst[1] RunWait ( $pathToDaemonTools & ' -unmount 1' ) RunWait ( $pathToDaemonTools & ' -mount 1, "' & $pathToIso & '"' )<{POST_SNAPBACK}>cool, thanks for posting the solution, it bugs me when people post a prob then fall off the planet because they resolved it, and others waste time trying to help Link to comment Share on other sites More sharing options...
LxP Posted August 12, 2005 Share Posted August 12, 2005 It probably doesn't matter anymore now but I believe that the problem with this code: RunWait(@comspec & '/k c:\Program Files\D-Tools\daemon.exe -demount 1') is that you were not surrounding the path to the .EXE in double quotes. This would probably work for you: RunWait(@comspec & '/k "c:\Program Files\D-Tools\daemon.exe" -demount 1') Link to comment Share on other sites More sharing options...
Muzzikap Posted August 12, 2005 Author Share Posted August 12, 2005 It probably doesn't matter anymore now but I believe that the problem with this code:RunWait(@comspec & '/k c:\Program Files\D-Tools\daemon.exe -demount 1')is that you were not surrounding the path to the .EXE in double quotes. This would probably work for you:RunWait(@comspec & '/k "c:\Program Files\D-Tools\daemon.exe" -demount 1')<{POST_SNAPBACK}>tnxz for your reply.Perhaps you or somebody else can tell me what the /k does. I don't get that part of the code. Link to comment Share on other sites More sharing options...
w0uter Posted August 12, 2005 Share Posted August 12, 2005 /k keeps the box open. /c closes the box. My UDF's:;mem stuff_Mem;ftp stuff_FTP ( OLD );inet stuff_INetGetSource ( OLD )_INetGetImage _INetBrowse ( Collection )_EncodeUrl_NetStat_Google;random stuff_iPixelSearch_DiceRoll Link to comment Share on other sites More sharing options...
Valuater Posted August 12, 2005 Share Posted August 12, 2005 tnxz for your reply.Perhaps you or somebody else can tell me what the /k does. I don't get that part of the code.<{POST_SNAPBACK}>This may helphttp://www.microsoft.com/resources/documen.../en-us/cmd.mspx8) Link to comment Share on other sites More sharing options...
therks Posted August 12, 2005 Share Posted August 12, 2005 (edited) That's a command line switch for cmd.exe or command.com./C Carries out the command specified by string and then terminates/K Carries out the command specified by string but remainsJust give this a try:Start > Run > "cmd /k echo Hello World" (without quotes)/c does the same thing, but closes cmd.exe right away, so it's useless for displaying things, but handy for doing something like"cmd /c del C:\temp\*.tmp"*Edit: Just so you know, @COMSPEC evaluates to whatever the command line utility is for your system (in my case "C:\WINDOWS\system32\cmd.exe" on my old Win98 system it would have been "C:\Windows\Command.com")*Edit2: Wow, 2 more replies while I typed mine.. I took too long I think.. Edited August 12, 2005 by Saunders My AutoIt Stuff | My Github Link to comment Share on other sites More sharing options...
LxP Posted August 13, 2005 Share Posted August 13, 2005 http://www.microsoft.com/resources/documen.../en-us/cmd.mspxThanks for sharing that -- I wasn't aware until now that the command prompt's colour scheme can be changed via a parameter and that it's possible to set commands to be run on every Cmd startup.Now I can get some alias functionality happening with Doskey! 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