LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how can i print the string and integer both together

Solved!
Go to solution
Highlighted

Hi,

 

My requirement is like printf statement in c.

I have the 32 bit array of integer data.

I want to print in the labview like 

 

u32Data [0] :  0x12345

u32Data [1] : 0x45566

 

similary in c code is

 

for (i=0; i<5; i++)

printf ("u32Data [i] : 0x%X ", i, u32Data [i]);

 

similarly like this how can print it in the string pallette or any other.

 

 

 

with regards and warm welcome,
Ramamoorthy S
0 Kudos
Message 1 of 4
(841 Views)
Highlighted
Solution
Accepted by topic author ramji44

Hi Rama,

 

use FormatIntoString in an autoindexing FOR loop:

check.png

Best regards,
GerdW

using LV2011SP1 + LV2017 (+LV2020 sometimes) on Win10+cRIO
0 Kudos
Message 2 of 4
(832 Views)
Highlighted

Can you please tell me.

How to create the macros in the labview.

 

 

Like below mentioned 

 

#define sqrt (x)   (x * x)

 

with regards and warm welcome,
Ramamoorthy S
0 Kudos
Message 3 of 4
(827 Views)
Highlighted

Hi Rama,

 

there are no "macros" in LabVIEW. There are built-in functions and functions made by you.

SQRT() is a built-in function available in the math/numerics palette! And you will also find a SQuaRe() function - it's irritating to name a term like "x*x" with a common abbrevation of SQuareRooT()!

 

Please stop creating duplicate posts! This is highly annoying...

Best regards,
GerdW

using LV2011SP1 + LV2017 (+LV2020 sometimes) on Win10+cRIO
0 Kudos
Message 4 of 4
(769 Views)