LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

loading a 2-d boolean array from a text file

Hi,
I am trying to load a 2-D boolean array from a text
or spread sheet file .
each line/row consists of 8 bit data in binary format.
Any advice would be greatly appreciated.TKS.
0 Kudos
Message 1 of 5
(2,826 Views)
Can you post an example of the file?

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
0 Kudos
Message 2 of 5
(2,826 Views)
Hi Mike ,

The file would look like this :

11111010
11010101
11111111
00000000
and so on until 50 bytes.

I could also use a spreadsheet file using eight columns and fifty rows..

Thanks .
0 Kudos
Message 3 of 5
(2,826 Views)
See if this is what you're looking for. Using your text example, the first row of the Boolean array will be True, True, True, True, True, False, True, True. The second row will be True, True, False, True, False, True, False, True, etc.
0 Kudos
Message 4 of 5
(2,826 Views)
Hi Dennnis,
Perfect solution.
Exactly what I was looking for.
Just had to seperate the binary data in the text file using tabs to spread the data across columns 0 to 7.

Thanks a lot !

Saravanan Dorairaj
0 Kudos
Message 5 of 5
(2,826 Views)