View Full Version : slider question

04 April 2006, 08:20 PM

I was wondering if there is a way to make the intslider or intsliderGrp's -changeCommand or -dragCommand flags to be executed when the value is changed and not only when the slider is changed.

What i want to do is connect an attrFieldSliderGrp to a custom node.
Then i want to connect the custom node to an intslider.

What this should do:
When i change the attrFieldSliderGrp's slider the intslider's slider should change and run a procedure because of the -changeCommand flag.

What it acctually does:
When i change the attrFieldSliderGrp's slider the intslider's slider changes but it doesn't run the procedure.

If anybody is wondering why i'm going thrue all the trouble of doing this it's because i want to be able to have a keyable slider that executes a command when changed. But since the intSlider isn't connected to an attribute it isn't keyable.

04 April 2006, 08:03 AM
cant you skip the intSilder and just use the attrFieldSliderGrp? or add -changeCommand to the attrFieldSliderGrp and execute the command when the attrFieldSliderGrp is changed and then update the intSlider.

04 April 2006, 09:38 AM
Thanks for the quick reply.

My problem is that both the intSlider's and the attrFieldSliderGrp's -changeCommand flag doesn't work when the value is change by an outside connection (like keyframes) they only work if you effect them directly by either dragging the slider or entering in a value in the field.

I'v been trying it out with scriptjobs as well. The scriptjob works well but then there is the problem of what i'm going to do when the user deletes the node that is connected to the scriptjob or when the user closes the scene.

Since a scriptjob can't be paranted to an object and it's deleted when the scene, or when maya is closed, they won't work.

CGTalk Moderation
04 April 2006, 09:38 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.