LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

"%.;" signifier in Format Into String

In various VISA instrument drivers, I often see the signifier "%.;" in the format string input of Format into String.  Can someone tell me what the purpose of this signifier is?  For example, in the Configure Channel vi of the Agilent 6000 driver ag6000a, the Format into String operation is used with the following inputs:

format string: %s:OFFS %.;%g V;
initial string:   CHAN1:COUP DC;
input 1 (str):   CHAN1
input 2 (dbl):   10

What purpose does the "%.;" in the above serve?

Thank you.

LRC
0 Kudos
Message 1 of 10
(3,988 Views)
%s signifies that the following characters contain combinations of letters/words and/or numbers but all are are in ascii string format.
PaulG.
Retired
0 Kudos
Message 2 of 10
(3,987 Views)

Hi LRC,

That modifier makes the drivers portable and usable with other versions of labview where the decimal seperator is not ".".  As you know in Europe the accepted notation is using a "," as the decimal seperator.

In other words they write 12,123 instead of 12.123.

We use the comma as a convenience to seperate 3 digits as a time to better read numbers and this usually happens in hand-written documents.

Going back to the "%.;" modifier, it ensures that a "." is used as the decimal seperator. 

Hope this answers your question.

Regards,
Berk
Instrument Drivers / IVI
Message 3 of 10
(3,982 Views)
I understand the purpose of the %s signifier, but what purpose does the %.; signifier serve?

LRC
0 Kudos
Message 4 of 10
(3,981 Views)
I see.  Thank you.
0 Kudos
Message 5 of 10
(3,980 Views)
I stand corrected, and you are right, Berko. Thanks. Smiley Happy
PaulG.
Retired
0 Kudos
Message 6 of 10
(3,943 Views)
Small correction,

in -SOME- parts of Europe, the decimal seperator is a comma instead of a point.  Ireland and England use a point, perhaps others too.

One of the first things I learned when I started programming LabVIEW in Switzerland.......

Shane.
0 Kudos
Message 7 of 10
(3,901 Views)

Isn't globalization a wonderful thing? At National Instruments we do our best to make our code ubiquitous across different countries and languages. Here is a Knowledge Base article that discusses all the localization codes in LabVIEW.

Maybe LabVIEW will be the common language for all of humanity, heralding a era of world peace through graphical programing. Got to dream right?


 
-Marshall R
0 Kudos
Message 8 of 10
(3,860 Views)
Oh, if you want to raise the topic of Globalization......

When will LabVIEW finally have native Unicode support?

Programming in C# has really opened my eyes in that regard.....

Shane.
0 Kudos
Message 9 of 10
(3,851 Views)

The support is there, but for ease of use for most users who only need to use their native language it is disabled for ease of use.  

 
-Marshall R
0 Kudos
Message 10 of 10
(3,838 Views)