Introduction to Maya - Rendering in Arnold
This course will look at the fundamentals of rendering in Arnold. We'll go through the different light types available, cameras, shaders, Arnold's render settings and finally how to split an image into render passes (AOV's), before we then reassemble it i
# 1 28-02-2013 , 02:53 PM
Registered User
Join Date: Feb 2013
Posts: 7

MEL - Syntax error

Hi, I'm completely new at maya and mel so bare with me user added image

When I try to call up the script it says: Error: D:/MyMelScripts/test.mel line 1.6: Syntax error
I understand from other posts I read, that I could be writing something wrong so here's my
spelling: source test.mel

The MyMelScripts folder was created by me, while the default was C:\Users\Irena\Documents\maya\2013\prefs\ScriptEdi torTemp - which I found weird but I first tried to call up my test.mel script from there, it came with the same syntax error. Which is why I added a MAYA_SCRIPT_PATH = D:\MyMelScripts to the env file to try and do the same thing from another folder.

When I open File>Source script from Script editor it still takes me to the default location.
I found in the ScriptEditorTemp two files named CommandExecuter and CommandExecuter-0. I don't know if that means anything. user added image

# 2 28-02-2013 , 03:41 PM
Gen's Avatar
Super Moderator
Join Date: Dec 2006
Location: South FL
Posts: 3,522
Could you post the first line of the script?


- Genny
__________________
::|| My CG Blog ||::
::|| My Maya FAQ ||::
# 3 28-02-2013 , 03:43 PM
Registered User
Join Date: Feb 2013
Posts: 7
I was just testing how to save scripts so I just wrote
"sphere"

And that's my entire script.

Edit: Okay, I'm a bit slow, sorry. If it's just sphere then it doesn't work, but I just tried adding move (and some values) to the script and it works fine, though it still works from the ScriptEditorTemp and not the path I added in .env file... but that's ok as long as I can save scripts at all.
Thanks for the help user added image

Edit2: lol, I spoke too soon. What I failed to realize is that if the script is saved in that folder it disappears after maya restarts or if I type in rehash command. :S I'm still getting the same error if I type in the source test.mel - even with the values I added (I actually just copied from the script editor window the values that appeared after I moved the sphere with move tool)

Edit3: I've found my mistake user added image It was a syntax error, in the .env file I put: \ instead of this: /
*feels like a proper newbee* :S


Last edited by IrenaDee; 28-02-2013 at 04:15 PM.
# 4 28-02-2013 , 04:15 PM
EduSciVis-er
Join Date: Dec 2005
Location: Toronto
Posts: 3,374
It sounds like the syntax error is related to your script, not how you're calling it.
"sphere;" would be the proper command.

# 5 28-02-2013 , 04:19 PM
Registered User
Join Date: Feb 2013
Posts: 7

It sounds like the syntax error is related to your script, not how you're calling it.
"sphere;" would be the proper command.

lol, you're right. user added image Found the error in the spelling when I put the new path in the .env file, still thank you for answering user added image

Posting Rules Forum Rules
You may not post new threads | You may not post replies | You may not post attachments | You may not edit your posts | BB code is On | Smilies are On | [IMG] code is On | HTML code is Off

Similar Threads