View Single Post
# 5 08-05-2003 , 06:57 AM
mark_wilkins's Avatar
Registered User
Join Date: Jan 2003
Posts: 161
Button action procedures can't have arguments. The best you can do is make the variable global:


// declare variables

string $a = "window";
string $b = "layout";
global string $c = "scrollListBox";


// some window creation commands here that i deleted ...

textScrollList -w 100 -h 100 -append "None" -selectCommand "updateChar" $c;

button -l "Refresh" -w 55 -c "refreshChar";


showWindow;

// procedures
proc refreshChar()
{
global string $c;

textScrollList -e -removeAll $c;
textScrollList -e -append "None" $c;

}


Mark R. Wilkins
author of MEL Scripting for Maya Animators
www.melscripting.com