08-12-2020 07:51 AM
Hi GerdW,
The last method for building string array I found that very helpful.
I have tried different cases for decimal correction, it didn't work. can you please tell me, how can I solve this problem?
08-12-2020 07:56 AM
Hi Shannara,
did you read the LabVIEW help on format codes by now?
%,2f is just WRONG!
Which decimal separator is your OS set to? Do you use the comma as decimal separator?
Which decimal separator is Excel (on your specific computer) expecting?
Does Excel also expect the tab used as delimiter in your CSV files?
Can you attach the text files you created?
08-12-2020 08:12 AM
In LabVIEW, the delimited separator is set to the localized decimal point and Excel also it is according to Germany which is set to comma as decimal separator.
"%,;" this formats the local delimited separator, right?
08-12-2020 08:26 AM
Hi Shannara,
@Shannara wrote:
In LabVIEW, the delimited separator is set to the localized decimal point and Excel also it is according to Germany which is set to comma as decimal separator.
Then go with a comma in the numeric data and the tab as delimiter in your text files.
Be warned: whenever you will get in contact with international customers/collaborators you will get into trouble with such TSV files very quickly. I recommend to use the point as decimal separator…
@Shannara wrote:
"%,;" this formats the local delimited separator, right?
Yes, %,; sets the comma as decimal separator when converting numbers into strings (or vice versa).
But still %,2f is plain wrong…
08-12-2020 08:33 AM
Is it right?
08-12-2020 08:35 AM
Hi Shannara,
still not right.
%,; just specifies to use the comma as decimal separator, but there is no information on how to format the floating point number!
Use %,;%.3f - and read the LabVIEW help on formatting codes again!
08-12-2020 08:45 AM
HI GerdW,
Sorry for disturbing you, I still didn't get the solution for it. I have got the values like this.
08-12-2020 09:17 AM
Is it possible, the timestamp can be converted into array format?
08-12-2020 09:29 AM - edited 08-12-2020 09:32 AM
Hi Shannara,
how often have I told you by now that %,2f (or %,3f) is plain wrong for a format code!?
Again: read the LabVIEW help on format codes!
Try this even more simple code:
(When the numbers already are converted to strings then it doesn't make sense to use a numeric format code for WriteDelimitedFile…)
@Shannara wrote:
Is it possible, the timestamp can be converted into array format?
Why do you need this?
And how should the array look like?
08-12-2020 09:39 AM
I mean, not in the string array format, I mean it should be like a numerical array format.
In this code format, it is saving the data as I need, the problem is with the timestamp, How can I convert time stamp in the numerical array format?