LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Format specifiers for spreadsheet to string

I have used the format specifiers many times before with no problems but this one has stumped me.  I scan a delimited spreadsheet string and convert it to string array.  I then write to a string table.  I would like the format to be X.XXE+N.   I have tried several of the examples to no avail.  One would think that %.2e should do the trick, I sure can't make her work.   All previous posts regarding format specifiers make sense to me, but do not seem to apply to this.  Does the "spreadsheet to string" act differently than other conversions?  Thanks for any help!
 
I have included my prototyping trials.  (LV7.1 on XP)
0 Kudos
Message 1 of 3
(2,356 Views)
What you need to do is first convert the string to a number. A format specifier of %.2e will only apply if the input is numeric. Converting a string to a string, you can only use %s.
Message 2 of 3
(2,347 Views)
Thanks Dennis, it is good to have a place to go for answers!
  That is not really what I wanted to hear though, that I would have to change the way I'm doing it, not just change a specifier.  That is going to take at least 1 more function to "wire-up".  Sarcasm is so hard to pen!!
 
Gold
0 Kudos
Message 3 of 3
(2,336 Views)