a3dmonkey
11-05-2002, 09:35 PM
I'm working on a script to create a twisting muscle. In this script I'm obtaining the number of section in a nurbs object and using that to dynamicly create a window with checkBoxes so that the number of Isoparms to be used in creating control wires for the muscle can be selected by the user.
I've gotten to the point in my script where I'm creating the window with checkBoxes with the following code
int $i = 0;
//for ( $i=0 ; $i < $sections ; $i++)
// {
string $tempISO = "Isoparm" + $i ;
checkBox -l $tempISO
-cc "select -tgl ( $objECT + ".v[" + $i +"]");";
// }
$sections - is and int and the number of sections in the nurbs object.
$tempISO - is a string that I'm using as the name of my checkBoxes.
$objECT - is the selected object[0].
// - The loops turned off till I get the checkBox info right. No problems here with test runs of the loop.
NOW THE PROBLEM ...
when executing the checkbox command I get the following error.
// Error: Too many arguments. Expected 1, found 2. //
I've tracked this error to the checkBox command and I'm thinking my syntax if off or something. I've looked throught a couple of books and the Mel node ref and have not been able to spot the cause of the error yet.
To any mel experts out there can please take a quick look at my checkBox syntax and let me know if I'm off the mark here.
Back off to animate, I'm creating this script to relax from animating and learn mel if you can believe it.
( lol relaxing )
Oh well , cheers all.
Michael Ware
SVA Grad Student
:buttrock:
I've gotten to the point in my script where I'm creating the window with checkBoxes with the following code
int $i = 0;
//for ( $i=0 ; $i < $sections ; $i++)
// {
string $tempISO = "Isoparm" + $i ;
checkBox -l $tempISO
-cc "select -tgl ( $objECT + ".v[" + $i +"]");";
// }
$sections - is and int and the number of sections in the nurbs object.
$tempISO - is a string that I'm using as the name of my checkBoxes.
$objECT - is the selected object[0].
// - The loops turned off till I get the checkBox info right. No problems here with test runs of the loop.
NOW THE PROBLEM ...
when executing the checkbox command I get the following error.
// Error: Too many arguments. Expected 1, found 2. //
I've tracked this error to the checkBox command and I'm thinking my syntax if off or something. I've looked throught a couple of books and the Mel node ref and have not been able to spot the cause of the error yet.
To any mel experts out there can please take a quick look at my checkBox syntax and let me know if I'm off the mark here.
Back off to animate, I'm creating this script to relax from animating and learn mel if you can believe it.
( lol relaxing )
Oh well , cheers all.
Michael Ware
SVA Grad Student
:buttrock:
