ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Write Text Data Array to text file

Greetings all. I hope someone can help me as I am really under the gun. The attached vi shows the basics of what I am trying to do. I have already written a vi that takes the Cal Data Array and prints it out in a nicely formatted report. My problem is that the powers that be also want the data saved to a generic text file that can be copied and printed out anywhere they like. As such, I need to save the data to a generic text file in column format such that it will all fit on one page in landscape mode. There are a total of 12 columns of data. I have been trying to create something that would format each column to a specific length instead of them all being the same. No luck so far. Basically, I need columns 1,2,3,8 and 12 to be length of 5. The rest a length of 9. I have tried to place the formatting part in a for loop with the formatting in a case, but it does not appear to work. I really need this quick so if anyone has any ideas, please help. As always, I really appreciate the assistance.
 
Thanks,
Frank
0 Kudos
Message 1 of 5
(3,408 Views)
This vi should do what you need.

Paolo
Paolo
-------------------
LV 7.1, 2011, 2017, 2019, 2021
Message 2 of 5
(3,390 Views)
pincpanter's is a good solution. Beat me to it while I was away building an example. Similiar approach using two for loops and case statement. Here is my suggestion anyway....
 
cheers
 
David
 

Message Edited by David Crawford on 11-23-2005 09:37 AM

Message 3 of 5
(3,380 Views)
Message 4 of 5
(3,371 Views)

Thanks to all you. Each vi presented the solution in a slightly different way which not only solved my problem for me but also taught me a little something also. I sincerely appreciate each of you taking the time to help me out. Take care.

Frank

 

0 Kudos
Message 5 of 5
(3,349 Views)