Copy link to clipboard
Copied
I am trying to get cfexecute to work. From a command line within drive d\lame on a Windows server if I run:
lame -b 128 "Abba - Dancing Queen.mp3" "Abba - Dancing Queen 128.mpe"
The file converts as expected.
From CF2016 if I run:
<cfexecute name="d:\lame\lame.exe"
arguments="-b 128 ""Abba - Dancing Queen.mp3"" ""Abba - Dancing Queen 128.mp3"""
outputFile = "D:\lame\output.txt"
>
Nothing happens. Output.txt is blank and the file doesn't convert. Doesn't even seem like lame.exe even executes.
Suggestions? (insert lame song jokes here)
Thanks, Gary
Hi ghanna1
I followed these steps:
<cfexecute name="d:\lame\lame.exe" arguments='-b 128 "d:\lame\Abba - Dancing Queen.mp3" "d:\lame\Abba - Dancing Queen 128.mp3"'></cfexecute>
It works as expected.
...
Copy link to clipboard
Copied
Copy link to clipboard
Copied
<cfexecute name="d:\lame\lame.exe"
arguments='-b 128 "d:\lame\Abba - Dancing Queen.mp3"
"d:\lame\Abba - Dancing Queen 128.mp3"'>
Copy link to clipboard
Copied
Copy link to clipboard
Copied
Actually, it supposed to be .mp3 on both.
Copy link to clipboard
Copied
Thanks for the suggestions. I tried BKBK's:
<cfexecute name="d:\lame\lame.exe"
arguments='-b 128 "d:\lame\Abba - Dancing Queen.mp3"
"d:\lame\Abba - Dancing Queen 128.mp3"'
I also tried adding timeout as Charlie suggested.
<cfexecute name="d:\lame\lame.exe"
arguments='-b 128 "d:\lame\Abba - Dancing Queen.mp3"
"d:\lame\Abba - Dancing Queen 128.mp3"'
timeout = "20"
outputFile = "D:\lame\output.txt">
I also tried Charlie's suggestion of running CMD:
<cfexecute name="c:\windows\system32\cmd.exe" arguments='/c d:\lame\lame.exe -b 128 "Abba - Dancing Queen.mp3" "Abba - Dancing Queen 128.mp3" '
timeout = "20"
outputFile = "D:\lame\output.txt">
Still no luck. Even if the arguments are wrong Lame.exe returns something. If CF is launching the exe shouldn't I see something besides an empty output.txt file created? I thought it would capture whatever lame.exe outputted.
Gary
Copy link to clipboard
Copied
Lame.exe only requires quotation marks if there are spaces in the input or output file. For a test, I renamed the input file to queen.mp3 and the output file to queen128.mp3. I ran the command line as:
lame -b 128 queen.mp3 queen128.mp3
which worked as expected.
I tried the same argument without quotes in CF and it works. So it's something wrong in how we're creating the argument with quotation marks.
<cfexecute name="d:\lame\lame.exe"
arguments="-b 128 d:\lame\queen.mp3 d:\lame\queen128.mp3">
Copy link to clipboard
Copied
Hi ghanna1
I followed these steps:
<cfexecute name="d:\lame\lame.exe" arguments='-b 128 "d:\lame\Abba - Dancing Queen.mp3" "d:\lame\Abba - Dancing Queen 128.mp3"'></cfexecute>
It works as expected.
Copy link to clipboard
Copied
BKBK,
Thanks for going through all that effort! I really appreciate it. I must have fat-fingered something the first time I tried your example. I also got it to work late last night using:
<cfexecute name="d:\lame\lame.exe"
arguments="-b 128 ""d:\lame\ABBA - Dancing Queen.mp3"" ""d:\lame\Abba - Dancing Queen128.mp3""" />
Appreciate everyone's help!
Gary