Multiple shell commands

Jan Schenkel janschenkel at yahoo.com
Sat Nov 6 11:33:16 CST 2004


--- "J. Landman Gay" <jacque at hyperactivesw.com> wrote:
> I want to send two commands to a command-line app
> using shell() on 
> Win98. The first needs to change directories, and
> then I need to issue a 
> command to a DOS app. Both of these work okay if I
> type them into the 
> DOS prompt window.
> 
> When I try to send them via shell() it always fails
> with "too many 
> parameters". I think I'm having trouble with quote
> marks, but I don't 
> know enough about shell on Windows to figure it out.
> Here are the 
> commands I want to send:
> 
> cd "C:\Program Files\Conversion
> Software\w32-rbmake-1.1\"
> 
> rbMake -ebjTs -otest "C:\Program Files\Conversion
> Software\README.txt"
> 
> How would you format these? I tried using single
> quotes around the file 
> paths but it doesn't work. Omitting the quotes
> entirely also fails, even 
> if I only send the first line. I have also read that
> we can use "&" to 
> join and send multiple commands to shell() but when
> I try it, I still 
> get "too many parameters" with the "&" shown as the
> culprit.
> 
> Anyone know how to do this?
> 
> -- 
> Jacqueline Landman Gay

Hi Jacque,

A few ideas :
- you may have to fiddle the 'shellCommand' property
(see Ken Ray's site)
- you could avoid the quotes in the file paths by
using the 'shortfilePath' function
- as a last rescue, you could write the two commands
to a temporary batch file, and then execute that file

Hope this helped,

Jan Schenkel.

=====
Join us at the European Revolution Conference
November 14-16, MALTA. ~ http://TechieTours.com/Rev/

=====
"As we grow older, we grow both wiser and more foolish at the same time."  (La Rochefoucauld)

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


More information about the use-livecode mailing list