Mailing List
Home
Forum Home
Softimage
Carrara
trueSpace
Dir3d-l
Maya - a powerful 3D animation and visual effects software
Macromedia Flash Development
Subjects
Cameras
scaleDown command
black out solved
Aircraft Tutorial
Mathematical XYZ ?
Its done This vs That
Its done first week
recommendations for screen video captures?
3DExplorer "Oddity "
New Director
ProTeam renewals
Fuel 's new websites (X post)
Blue peter create a make toy
targeting groups question
XPost: Shockwave 3D game ( sort of )
RES: RES: RES: Fish Modeling
Emitting particles from object intersection
Fuel 's new websites (X post)
Texturing
Big Break Contest Videos
New Plugins
Models and Texture on my updated site
Error Installing Patch tS6 6
Plasma?
Looking for Inspiration
Weird EMail Q
It 's done first week ?
Cherry not cranberry
New game
Camera Animation Problem
Particle plugins?
 
Mel SYSTEM calls

Mel SYSTEM calls

2003-12-04       - By Andy Rawling

 Back
Reply:     1     2     3     4     5     6  

Check how you're getting that $workSpace variable. Maya on windows uses
unix-style ('/') directory delimiters internaly, rather than ms-dos
style escape characters ('\') - and if you pass a unix path through to a
DOS comand, it's going to think you're setting bad options. The
'toNativePath' command should sort you out.

Last time I used 'start' I think I had to double-escape the DOS
delimiters to get them passed through ok:
   syetem( "start C:\\\\PROGRA~1\\\\BLAH.EXE" );
rather than just
   system( "C:\\PROGRA~1\\BLAH.EXE 2>NUL" );
could be wrong though - that was some time ago.

- Andy

Dobson, Jeff wrote:

>The system command should appear in quotes (") as opposed to ticks "`" in
>this case.  Of course that means you will have to wrestle with escape
>characters to get the quotes within quotes syntax correct.  I find it
>easiest to first build my command in string and then feed it to the system
>command.  That bails me out of a lot of syntax trial and error.
>
>string $callCmp = "start cmpPackage.exe " + $workSpace + "
>directory\\fileName.ext";
>print ($callCmp + "\n");  //This is a debug line so the script ed will show
>you exactly what you are feeding to the system command
>system ($callCmp);
>
>It has been a while since I have done this, though.  You might need to
>include "system" in the string and eval the string instead.
>
>--JeffD
>
>-- --Original Message-- --
>From: Brian Bullock [mailto:Brian@(protected)]
>Sent: Wednesday, December 03, 2003 9:27 AM
>To: maya@(protected)
>Subject: Mel SYSTEM calls
>
>
>
>
>I'm trying to write a mel script that will open a cmp file based on the
>workSpace variable and a set cmp name.
>
>
>EG:
>
>system ('start cmpPackage.exe " + $workSpace + "directory\\fileName.ext');
>
>
>I'm trying to run the script off the top of my head and there maybe syntax
>problems, but hopefully you get the point...
>
>
>Any ideas?
>
>
>-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---
>List-help: <mailto:listar@(protected)?Subject=help>
>List-unsubscribe: <http://www.highend3d.com/maya/listserver/>
>List-subscribe: <http://www.highend3d.com/maya/listserver/>
>List-archive: <http://www.highend3d.com/maya/archive/>
>
>-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---
>List-help: <mailto:listar@(protected)?Subject=help>
>List-unsubscribe: <http://www.highend3d.com/maya/listserver/>
>List-subscribe: <http://www.highend3d.com/maya/listserver/>
>List-archive: <http://www.highend3d.com/maya/archive/>
>
>  
>



-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---
List-help: <mailto:listar@(protected)?Subject=help>
List-unsubscribe: <http://www.highend3d.com/maya/listserver/>
List-subscribe: <http://www.highend3d.com/maya/listserver/>
List-archive: <http://www.highend3d.com/maya/archive/>