Formatting and I/O Library Chapter 2
LabWindows/CVI Standard Libraries 2-58 © National Instruments Corporation
Writing a Line Containing an Integer with Literals to the Standard Output
int a, b;
a = 12;
b = 34;
FmtOut ("%s<A = %i\n", a);
FmtOut ("%s<B = %i\n", b);
Remarks
In this example, the output is as follows:
A = 12
B = 34
Writing to the Standard Output without a Linefeed/Carriage Return
char *s;
int b;
double c;
a = "One ";
FmtOut ("%s<%s", a);
b = 2;
FmtOut ("%s<%i", b);
c = 3.4;
FmtOut ("%s<%f", c);
Remarks
This example demonstrates how to write to the Standard Output without a linefeed/carriage
return by omitting the '\n' from the format string. The output in this example is as follows.
One 2 3.4
The following code produces the same output:
a = "One";
b = 2;
c = 3.4;
FmtOut ("%s<%s %i %f", a, b, c);