[Gambas-user] Exec statement not working though equivalent Terminal command works
John Rose
john.aaron.rose at ...626...
Wed Jul 9 09:32:30 CEST 2014
I have this code:
Print "mplex", "-f 8", "-o " & "'" & sCombinedPath & "'", "'" &
sVideoPath & "'", "'" & sAudioPath & "'"
Exec ["mplex", "-f 8", "-o " & "'" & sCombinedPath & "'", "'" &
sVideoPath & "'", "'" & sAudioPath & "'"] To sOutput
I'm using the single quotes since they are required when entering the
equivalent commands in a Terminal e.g. mplex -f 8 -o
'/home/john/Videos/q.mpg' '/home/john/Videos/The Story of Science_
Power, Proof____20140621_2000.m2v' '/home/john/Videos/The Story of
Science_ Power, Proof____20140621_2000.mp2'.
The Print statement shows (at runtime):
mplex -f 8 -o '/home/john/Videos/q.mpg' '/home/john/Videos/The
Story of Science_ Power, Proof____20140621_2000.m2v'
'/home/john/Videos/The Story of Science_ Power, Proof____20140621_2000.mp2'
i.e. the exact equivalent of the working command when entered in a
Terminal.
However, the Exec statement does nothing at runtime, though the
equivalent Terminal command works. There is no feedback on why by
Gambas. I've also tried the statements without the single quote usage &
it also did nothing. I'm fairly sure that this used to work on the
previous version of Gambas: I'm using kendek's Gambas3 ppa
(https://code.launchpad.net/~nemh/+archive/ubuntu/gambas3) which
installed Gambas 3.5.3. The code without the single quote usage is:
Print "mplex", "-f 8", "-o " & sCombinedPath, sVideoPath, sAudioPath
Exec ["mplex", "-f 8", "-o " sCombinedPath, sVideoPath, sAudioPath]
To sOutput
The above sOutput variable has the value "". What I am doing wrong or is
it an issue in Gambas 3.5.3?
--
Regards,
John
More information about the User
mailing list