LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

string to 32 bit integer

Can anybody guide me how to convert string to 32 bit Integer? I am trying to convert it but getting some error. Can anybody please look at attached VI and guide me where is the mistake. 

 

Thanks

 

JK

 

 

0 Kudos
Message 1 of 3
(1,786 Views)

JK,

 

i am sorry, but neither your post nor the VI shows what you want to achieve. I assume that you get a numeric string (i.e. a string with numeric symbols only) which you want to convert into an array of numeric values.

 

Your VI on the other hand shows a "binary" string. So another option would be: take 32 elements of the string, convert it to a 32bit integer, then proceed with the next 32 characters.

This would require though that the string only contains '1' and '0' and no other character.

 

Please provide more information.

 

Norbert

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 2 of 3
(1,751 Views)

What are you expecting for an output?  What is the format of your string?

 

Assuming it is to be a 32 character string of just "0" and "1", then Scan From String will be your friend here.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 3 of 3
(1,719 Views)