PDA

View Full Version : From textScrollList to scrollField


Dreppan
09-06-2006, 10:19 PM
I need to change a MEL script from using textScrollList to using scrollField instead -- but need help to changing the syntax of the below lines.

string $rigList[] = `textScrollList -q -ai "CE_rigList"`;
textScrollList -e -append $tokens[0] "CE_rigList";
string $sel[] = `textScrollList -q -si "CE_rigList"`;
textScrollList -e -ri $each "CE_rigList";

A global replace does not work, as some of these parameters do not exist for ScrollField. Any MEL wizards are most welcome, as I am running into myriad issues - thanks!

jadamburke
09-07-2006, 04:51 AM
i don't think you can do what your asking. The scrollField is for entering/displaying multiline text like in the notes section of the attribute editor. It doesn't have selectable items like the textScrollList.

Dreppan
09-07-2006, 04:20 PM
I found a few solutions, here they are:



// EQUIVALENT OF :

// string $rigList[] = `textScrollList -q -ai "CE_rigList"`;

string $rigList = `scrollField -q -text "CE_rigList"`;


// EQUIVALENT OF :

// textScrollList -e -append $tokens[0] "CE_rigList";

scrollField -e -insertionPosition 0 "CE_rigList";

scrollField -e -insertText ($tokens[0] + "\n") "CE_rigList";


// EQUIVALENT OF :

//string $sel[] = `textScrollList -q -si "CE_rigList"`;

string $sel = scrollField -q -selection "CE_rigList";

CGTalk Moderation
09-07-2006, 04:20 PM
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.