View Full Version : how to delete expressions??

01 January 2008, 04:28 PM

I am trying to delete objects' expressions using Python, using the following code:

#option 1 (e = expression name)

#option 2, r=1)

But both give me the error: "TypeError: Object expression1 is invalid #"

But it seems to work in MEL, at least when I type it in the script editor...

Does anybody know how to solve this? Or maybe is there a better way to delete all expressions from a given object?

Thank you!

01 January 2008, 04:29 PM
in the scriptEditor, this code works:

import maya.cmds as cmds

node = "pCube1" (node, replace=1)
cmds.delete (expressions=1)

CGTalk Moderation
01 January 2008, 04:29 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.