If you have a filename knob named 'fname', you could create a python script
button and set its script to:

nuke.scriptSaveAs(filename=nuke.thisNode()['fname'].value())

Is that what you want?

Incidentally, I would argue this sort of feature would go not in a gizmo
floating around the DAG, but as a panel somewhere or possibly a tab in the
root.

-E


On Wed, May 8, 2013 at 2:54 PM, [email protected] <
[email protected]> wrote:

> **
> Hello!
>
> I have one, possibly, simple question for you. I am new to the world of
> python/tcl-scripting so go easy on me.
>
> I want to create a gizmo containing two knobs: one filename-knob and one
> button. In the filename-knob I want to be able to fill in a path to which I
> want to save my script, this is of course easy. And as I press the button I
> want the script to be saved to the path and the value of my filename-knob
> which contains not only the path but also the scriptname along with the
> extension .nk. Is this possible,? If so, how do I fullfill my needs and my
> goals in life?
>
> _______________________________________________
> 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

Reply via email to