# Select Components

**URL:** https://forum.highend3d.com/t/select-components/3578
**Category:** Maya
**Tags:** mel
**Created:** [October 8, 2005, 4:39pm UTC](https://forum.highend3d.com/t/select-components/3578 "2005-10-08T16:39:04Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![pete1973](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/p/d78d45/32.png) [@pete1973](https://forum.highend3d.com/u/pete1973)
#### Post date: [October 8, 2005, 4:39pm UTC](https://forum.highend3d.com/t/select-components/3578/1 "2005-10-08T16:39:04Z")

</div>

hy,

this is maybe really too simple, but i don't seem to understand  
how to do it.  
i want to select a curve and from that selection i wan't to select the  
contained cvs one by one.  
how do i have to do that?

---

<div class="post-metadata">

### Author: ![ewerybody](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/e/bcef8e/32.png) [@ewerybody](https://forum.highend3d.com/u/ewerybody)
#### Post date: [October 8, 2005, 6:43pm UTC](https://forum.highend3d.com/t/select-components/3578/2 "2005-10-08T18:43:39Z")

</div>

humm.. sounds stupidly simple but whats the command for listing the CVs.. or getting the number of CVs?!?!

But theres an undocumented mel-command selectCurveCV that does the job. You can see it If you do the Ctrl-RMB-thingy on a curve.

A look into the selectCurveCV.mel should clarify I guess 😜

Aaahhh its not a command it an attribute:

getAttr -size ($curve + ".controlPoints")

---

<div class="post-metadata">

### Author: ![failure](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/f/f08c70/32.png) [@failure](https://forum.highend3d.com/u/failure)
#### Post date: [October 8, 2005, 10:32pm UTC](https://forum.highend3d.com/t/select-components/3578/3 "2005-10-08T22:32:34Z")

</div>

CODE  
select -r curve1.cv["\*"];  
string $cvs[] = `ls -sl -fl`;  
select -cl;  
string $c;  
for( $c in $cvs ){  
 &nbsp; select -r $c;  
 &nbsp; // do something with each cv here  
}

---

<div class="post-metadata">

### Author: ![ewerybody](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/e/bcef8e/32.png) [@ewerybody](https://forum.highend3d.com/u/ewerybody)
#### Post date: [October 8, 2005, 11:48pm UTC](https://forum.highend3d.com/t/select-components/3578/4 "2005-10-08T23:48:14Z")

</div>

CODE  
select -r curve1.cv["\*"];

that works?!?!?!?!? ![](http://www.highend3d.com/boards/style_emoticons/<#EMO_DIR#>/blink.gif)

whoaar! Thats completely new to me! very interesting!!

Thanks failure!

---

<div class="post-metadata">

### Author: ![naughty](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/n/35a633/32.png) [@naughty](https://forum.highend3d.com/u/naughty)
#### Post date: [October 10, 2005, 8:40am UTC](https://forum.highend3d.com/t/select-components/3578/5 "2005-10-10T08:40:16Z")

</div>

QUOTE(ewerybody @ 10/08/05, 03:48 PM)  
CODE  
select -r curve1.cv["\*"];

that works?!?!?!?!? ![](http://www.highend3d.com/boards/style_emoticons/<#EMO_DIR#>/blink.gif)

whoaar! Thats completely new to me! very interesting!!

Thanks failure!  
[snapback]216845[/snapback]

don't bother messing about with select though, just do:

ls -fl "curve1.cv[\*]";

---

<div class="post-metadata">

### Author: ![joojaa](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/j/5daacb/32.png) [@joojaa](https://forum.highend3d.com/u/joojaa)
#### Post date: [October 10, 2005, 1:08pm UTC](https://forum.highend3d.com/t/select-components/3578/6 "2005-10-10T13:08:32Z")

</div>

One note and wrning about maya uncdcumented mel procs! They arent all avaiable in all modes of maya for exmaple they migt be auxiliary scripts for some prgrammers internal proc that may or may not source in batch mde for example.

---

<div class="post-metadata">

### Author: ![pete1973](https://forum.highend3d.com/letter_avatar_proxy/v4/letter/p/d78d45/32.png) [@pete1973](https://forum.highend3d.com/u/pete1973)
#### Post date: [October 10, 2005, 5:51pm UTC](https://forum.highend3d.com/t/select-components/3578/7 "2005-10-10T17:51:04Z")

</div>

thanks a lot guys,   
i don't know what i would do without the people  
in this forum
