Quantcast
Channel: LabWindows/CVI topics
Viewing all articles
Browse latest Browse all 5365

String comparison CVI If loop

$
0
0

Hello

im using if loop for comparing a char and making decision, but if condition is not working 

 

here is my code 

 

strncpy(BufString, &readBuf[0], 3);
BufString[3] = '\0';
Fmt (outMessage, "%s<%s%s%s","Power supply \"",BufString,"\" ");
MessagePopup ("Status", outMessage);

if (BufString == 'VOL')
{

Fmt (outMessage, "%s<%s%s%s","Power supply \"", BufString, "\" ");
MessagePopup ("Status", outMessage);
}

though value of BufString is VOL, condition inside if loop dosnt execute


Viewing all articles
Browse latest Browse all 5365

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>