Please find the below python code in maya. i am creating a ScrollList and 
trying to get the item selected in it and check the selected item using If, 
where as i am not able to check the if condition with the retrieved seleted 
name, but i do get the selected item if i print it.The IF condition is not 
working any reason or the way am checking is wrong??

cmds.iconTextScrollList("ListMenu", sc = GetItem, h= 280, append=('Camera', '  
Set Shot')

def GetItem():
    selectedItem = cmds.iconTextScrollList("ListMenu", si=True, q = True)
    print selectedItem
    if selectedItem == 'six' :
        print "SIX"

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].


Reply via email to