LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Significant Digits in data file

Solved!
Go to solution

Is there a way to change the significant digits in an LVM data file? I'm using "Write to measurements file"

0 Kudos
Message 1 of 11
(3,845 Views)

Depends. What do your "signals" data look like?

PaulG.

LabVIEW versions 5.0 - 2020

“All programmers are optimists”
― Frederick P. Brooks Jr.
0 Kudos
Message 2 of 11
(3,830 Views)

Signals? They're waveforms, voltages...

0 Kudos
Message 3 of 11
(3,819 Views)

Hi,

 

I'd use the "Write to Sreadsheet File" VI instead. It'll write your results to a text file and you can specify the format.

 

-CC

----------------------------------------------------------------------------------------------------------------------------
"If anyone needs me, I'll be in the Angry Dome!"


0 Kudos
Message 4 of 11
(3,787 Views)

I'm not sure I can do it with "write to spreadsheet." It doesn't have a "Saving Data" boolean. A lot of my program is dependent on that. Is there any other way to change the significant digits in a "write to measurements file"?

0 Kudos
Message 5 of 11
(3,777 Views)

Put the Write to Spreadsheet File function inside a case structure.

 

There is no easy way to change the number of digits using the Express VI.  You'd have to convert the Express VI to a regular subVI through the Open Front Panel menu option.  Then you'd have to drill down quite a few levels of subVI's and find where the format string is and change it.  Then you'd have to save that entire hierarchy of subVI's under new names.  I don't recommend any of this.

Message 6 of 11
(3,773 Views)
Solution
Accepted by topic author glskinner

Caution! This will change files in vi.lib. I suggest you rename and move the affeted vis (do not blame me if other things break)

 

Convert the express vi to a vi

Drill to here in the heirarchy

Capture.PNG

Change this constant format specifier

Capture1.PNG


"Should be" isn't "Is" -Jay
0 Kudos
Message 7 of 11
(3,763 Views)

Jeff, I think I tried this method before...exactly what do I put in the string to output only 3 significant digits?

0 Kudos
Message 8 of 11
(3,744 Views)

%.3g


"Should be" isn't "Is" -Jay
Message 9 of 11
(3,739 Views)

does the semi colon stay?

0 Kudos
Message 10 of 11
(3,733 Views)