Jump to content
Mzigaib

Use python to check if a parameter exists

Recommended Posts

How can I check with python if a parameter exists in a node?

There is this function on the manual but I could not make it work
 

def parm_exist(parmpath):
    nodepath, parmname = os.path.split(parmpath)
    node = hou.node(nodepath)
    return node.parmTuple(parmname) != None

 

Any tips?

Share this post


Link to post
Share on other sites
def check_parm_exists(parm_name, node):
	return node.parm(parm_name) is not None

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×