PDA

View Full Version : my script is doing what i don't want to do


h0tice
07-07-2003, 07:03 AM
hi there mel masters,

i got a problem in my script,

what i want to do: i want to list all the file nodes in maya and select them all, so i got this script,

string $asNode = `shadingNode -asTexture file`;
string $text[] = `ls -type $asNode`;
select -r "$text[0]";

but unexpectedly it is just creating a file node and not selecting the file nodes in the scene and printing an error like this


// Error: file: /home/demo/maya/scripts/conformText.mel line 4: Unknown object type: file1//

what am i doing wrong?

thanx

:buttrock:

nendo
07-07-2003, 07:25 AM
Hi !

try this:

string $listFilenode[]=`ls -tex`;
select -r $listFilenode;

h0tice
07-07-2003, 07:53 AM
:applause:

thanx nendo that was quick. iowe you one.

thanx again

CGTalk Moderation
01-15-2006, 02:00 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.