I found the solution to my own problem
I've changed it to
for n in nuke.selectedNodes():
n.knob('label').setValue( n['file'].value().split('/')[13])
this seems to work, but now I have new problem
I want to have this script has a tool from a drop down menu, I've saved it as
setlLabel.py in my plugins folder, and edited my menu.py with
import setLabel
m.addCommand("Set Read Label", "setLabel.setLabel()")
But now nuke wont start
RP
_______________________________________________
Nuke-python mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python