If you're feeding your file knob with a string formatted that way (SEQUENCE firstframe-lastframe), then you'll want to use the fromUserText() method instead of setValue()
So, your last line should read: loadFile["file"].fromUserText(inFile) On Mon, Aug 27, 2012 at 2:17 PM, teidenzero < [email protected]> wrote: > ** > Hello guys, > I'm quite new to python in Nuke so this is probably a silly mistake I'm > making. > I found some solutions about this issue on the forum but none of them seem > to work if I use a variable, or I fail to integrate the variable with the > syntax. > > this is my script > > #GUI > cp = nuke.Panel("Loader", 450) > platePath = cp.addClipnameSearch("Plate Loader","") > choice = cp.show() > if choice == 1: > inFile = cp.value("Plate Loader") > loadFile = nuke.createNode("Read") > loadFile["file"].setValue(inFile) > > the script does what I'm telling it to do: it prints the filename into the > "file" knob of the newly created Read node but the Read node returns an > error. > > This is how the "File" knob looks like: > E:/REEL/PitOfSouls/renders/comp/test/test_04/test_04.####.exr 1-225 > > now, if I delete the 1-255 from the filename it works perfectly. > > Any help? > > thank you very much > > _______________________________________________ > Nuke-python mailing list > [email protected], http://forums.thefoundry.co.uk/ > http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python > >
_______________________________________________ Nuke-python mailing list [email protected], http://forums.thefoundry.co.uk/ http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-python
