08-29-2010 02:12 PM - edited 08-29-2010 02:15 PM
Hi Guys
I wrote a simple conditional code in formula node and there is no error but it doesn't calculate. It works wrong and when I check the code I can't find any mistake.Please read my code and Let me know what is wrong with my code.
Thanks so much
Solved! Go to Solution.
08-29-2010 02:18 PM
theres no error, but you used for example "if (A=0)". = is NOT a comparison operator, I think you mean "if (A==0)" which compares A to zero...
Try it like this...
Hope this helps
christian
08-30-2010 03:37 AM
Thank you christian
It done
08-30-2010 10:24 AM - edited 08-30-2010 10:25 AM
It's fairly clear you are a text-based programmer. You should learn to do things the LabVIEW way. Here is your formula node code written in LabVIEW:
Note that you should NOT perform a direct comparison to zero with floating point numbers. This issue has been discussed MANY times in this forum (example search) and has nothing to do with LabVIEW, as it is an issue with the way numbers are stored with computers.
08-31-2010 06:44 AM
Oh thank you for labviewing
I like Labview way. infact I perfer combination some times it is more quick to write code. and less wires too.
Thank you for the point about comparision to ziro with floating point numbers.I didn't know it.