LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

converting 1D integer array to string array

Hi,
Please help in in solving this problem.
I have 3 1D integer arrays.I want each respective index of integer array to get concatenated as string and build a single 1D string array.
This 1D string array i want to convert it back to 1D integer array.
I have written C logic in teh text file for better understanding.So please let me know with a block diagram.
 
Thanks in advance.
0 Kudos
Message 1 of 10
(6,167 Views)
Hi!
   Your C is quite a metacode, it's in C++ that you can overload "+" operator to concatenate string, no?

   Anyway, that's it!

   Have a nice day!

graziano

Message 2 of 10
(6,145 Views)
This can be done without allocating as much memory. Simply multiple the 100's place and 10's place arrays by there respective place and sum the arrays. 

Message Edited by Stradis on 10-11-2007 02:35 AM


Paul
Message 3 of 10
(6,145 Views)
Thank you very much for the quick reply and valuable answers.
Thanks a lot!!!
0 Kudos
Message 4 of 10
(6,134 Views)
I have another query.Please solve this one also.
I have a string R20G0B255.
I need to seperate this string into 3 values.
ie i want input to my 3 variables Red, Green , Blue as 20, 0, 255.
I have attached a meta code again for better understanding.
 
Thanks in advance
 
 
0 Kudos
Message 5 of 10
(6,133 Views)
Hi Stradis!

   Of course, you're right, but the desired out was a string array, and I used this code to avoid zeros to be canceled when in front of the string! Smiley Happy

   Have you all a nice day!

graziano

  
0 Kudos
Message 6 of 10
(6,129 Views)
see below... anything else? It seems you are not trying to do any of this yourself.  Is there a reason?  You will find support running short, with such basic and simple questions. 

Message Edited by Stradis on 10-11-2007 03:02 AM


Paul
Message 7 of 10
(6,130 Views)
Hi Labview programmer_3181,
   You're asking something very simple, but... try to do it yourself! In this post I leaved the function names to let you search in the functions palette to "discover" other useful functions... try to do yourself the RGB decomposition, it's quite simple, unless you're gonna post each 5 minutes and learn nothing!!! Smiley Wink

   Bye!

graziano
Message 8 of 10
(6,128 Views)
Thanks yaar,
I tried and succeded in RGB decomposition.
Actually mine is time critical project and i am new to use of labview programming.
Thanks to all the members who are helping me all the time when needed.
By the way i have another problem of converting 2D integer array to 2D string array.
Please post me with the block diagram.
Thanks to all of you in advance
0 Kudos
Message 9 of 10
(6,110 Views)
See attached.  Again, a built in function.... You know, labview has a help function... you would be quicker searching that first.
This function is polymorphic and will handle arrays as well as discreet.


Message Edited by Stradis on 10-11-2007 04:46 AM


Paul
Message 10 of 10
(6,108 Views)