dwalden74
07-21-2003, 03:56 PM
Hi guys-
I have to match selected channelbox channels (`channelBox -q -sma`) with attribute names read in from a text file. The attributes in the text file are in their long-name form("translateX", "rotateZ" ...). However, querying the selected channels using the `channelBox`command only returns the channelsī short names ("tx", "rz" ...). Therefore the strings will not be equal each other (Iīm using "if ($textFileAttr == $selectedChannelAttr)" to test whether or not the strings are equal). On a side note, there is the "-longNames" flag for the `channelBox` command, however this only returns whether or not the queried channelbox is displaying long names (it does not return the channels in there long-name form - what a bummer).
The items in the text file I am reading are queried character set members (`character -q $character`). Once again, a lame paradox: querying the character members only returns attributes in their long-name form, and therefore I have to store the attribute names in the text file using their long names. Argh!
Question:
Does anyone know a fast way of converting attributesī long names to short names, or vice-versa? Or do I need to write another procedure to do this?
:beer:
David
I have to match selected channelbox channels (`channelBox -q -sma`) with attribute names read in from a text file. The attributes in the text file are in their long-name form("translateX", "rotateZ" ...). However, querying the selected channels using the `channelBox`command only returns the channelsī short names ("tx", "rz" ...). Therefore the strings will not be equal each other (Iīm using "if ($textFileAttr == $selectedChannelAttr)" to test whether or not the strings are equal). On a side note, there is the "-longNames" flag for the `channelBox` command, however this only returns whether or not the queried channelbox is displaying long names (it does not return the channels in there long-name form - what a bummer).
The items in the text file I am reading are queried character set members (`character -q $character`). Once again, a lame paradox: querying the character members only returns attributes in their long-name form, and therefore I have to store the attribute names in the text file using their long names. Argh!
Question:
Does anyone know a fast way of converting attributesī long names to short names, or vice-versa? Or do I need to write another procedure to do this?
:beer:
David
