LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

byte to string array

Solved!
Go to solution

Dear,

 

I need to build a string containing 205 bits from an array, any idea what is the simplest way to do that?

 

Tahnks in advance for your help

0 Kudos
Message 1 of 7
(2,507 Views)
Typecast?
0 Kudos
Message 2 of 7
(2,500 Views)
You don't say wat the datatype of the array is or how the string should look like. If the above does not solve your problem, we need more information. 😉
0 Kudos
Message 3 of 7
(2,496 Views)
Solution
Accepted by topic author BENIO

Hi,

 

thanks for your quick reaction.please find the picture which explain more what I need to do.

0 Kudos
Message 4 of 7
(2,462 Views)

Sorry, I missed your response. Did you solve the problem in the meantime?

 

OK, this is a bit more complicated but still quite easy. Use a FOR loop and autoindex over the string array on the left.

Inside the loop, get the single-character substring from each of the three inputs on the right starting with [i] and reformat the main string element accordingly. Build the output string at an autoindexing output tunnel.

 

If this is not clear, please attach a simple VI containing your controls with reasonable default data.

0 Kudos
Message 5 of 7
(2,430 Views)

Hello altenbach,

 

Yes I have solved the problem by using a FOR loopand using string subset and replace the entire array.

It is working now.

 

Thanks for your advise. 

0 Kudos
Message 6 of 7
(2,400 Views)

@BENIO wrote:

Yes I have solved the problem by using a FOR loopand using string subset and replace the entire array.



In the first post you asked for the "simplest way". This looks way too complicated and convoluted. I am sure it could be done with 80% less code. 😉

0 Kudos
Message 7 of 7
(2,381 Views)