09-21-2006 02:44 PM
09-21-2006 02:56 PM
09-21-2006 03:13 PM
As dan_u said, Ben's posting is surely a much more elegant method!
D'oh! I've used that method for string displays and file writes, but just didn't think of it for the string compare. It's definitely better than the method in my earlier post.
-Kevin P.
09-22-2006 07:27 AM
Thanks again to everyone who responded with even more possible solutions to this issue. It appears that you can't just wire in two different enums, no matter their dimension, just to check what their string values are (enums are strictly typed, and you have to have the same elements in the same order for enums to wire together). The only way to do it with a sub VI is to pull a reference to the enum. Is using a lot of references in a VI a performance hit? I remember that being mentioned somewhere? Also, as was mentioned by the poster (thanks Matt W), you have no control over when the references are read.
Can anyone help me out with what Matt W meant by adding "dup references out"? Are you to check the output references, to make sure they are equal when they come out to what came in? Is that a protection against the references changing during the sub VI's execution? I am just wondering what added feature or protection this would provide.
I fear that the best way to approach the task is to write the same 3-function code (two "Format Into Strings" and one "Equals") every time the comparison is needed directly in the main VI (thanks Ben, I only wish this method could be used in a sub VI).
Again, I would really like to express my gratitude for all of the replies. If I am wrong, and a better method exists from a speed of coding and VI performance point of view than using the same small chunk of code over and over again in the main VI, I'd really love to hear it.
Have a wonderful day!
09-22-2006 03:54 PM