From: rlg50 on
I
have a string input separated with tabs and end ofl ine constants. I am
trying to extract the separated items and send them to their
corresponding places in a cluster. In the example code that I have
provided, the first item that is extracted is a number and it is sent
to the cluster number. The second item is the sting element in the
cluster that is inside of the array that is insided the main cluster (i
hope that makes sense). I have the first part working in my other code,
but I am unable to get items to to the array in the internal cluster.
Please help. You will notice that there is a straight through path for
case 1 and I am thinking that this is needed in order to get into the
main cluster and then deal with it as a second entitiy, therefore I
have the second for loop and case structore. The string that I was
testing with is: \r\t400\r\n\ttest\r\n\t. Also, if I need to I can
create a separate post for thi


stringtoclst.vi:
http://forums.ni.com/attachments/ni/170/267453/1/stringtoclst.vi


stringtocllstprm.ctl:
http://forums.ni.com/attachments/ni/170/267453/2/stringtocllstprm.ctl


stringtoclst.ctl:
http://forums.ni.com/attachments/ni/170/267453/3/stringtoclst.ctl
From: altenbach on
Why so exceedingly complicated!!!! (You're creating fodder for the <a href="http://forums.ni.com/ni/board/message?board.id=BreakPoint&amp;message.id=2634" target="_blank"> Rube Goldberg code</a>&nbsp;Thread!)
&nbsp;
All you need is the following (I disconnected the typdefs, so please reconnect them if needed). There are probably quite a few other easy ways to do this.
&nbsp;
<img src="http://forums.ni.com/attachments/ni/170/267459/2/StringtoclstMOD.png">
&nbsp;
&nbsp;Message Edited by altenbach on 08-24-2007 09:08 AM


stringtoclstMOD.vi:
http://forums.ni.com/attachments/ni/170/267459/1/stringtoclstMOD.vi


StringtoclstMOD.png:
http://forums.ni.com/attachments/ni/170/267459/2/StringtoclstMOD.png
From: altenbach on
&nbsp;


rlg50 wrote:How do you creat the cluster input that is in the VI you posted?


Sorry, I don't know what you mean. The bundle functions always have a cluster input, so I did not have to create those.
To create the clusters for these inputs, I simply used your typedefs and disconnected them from the type definition (right-click...disconnect...). Just substitute your typedefs back and you should be good to go. :)