10-28-2005 10:37 PM - edited 10-28-2005 10:37 PM
Message Edited by Dynamik on 10-28-2005 10:44 PM
10-29-2005 02:25 AM
10-29-2005 10:41 AM - edited 10-29-2005 10:41 AM
This sounds like it could be a bug AND normal operation.
There are bugs in LV 7.1, 7.0 and possibly earlier that cuases LV to choose the wrong value when bundling and un-bundling by name.
I have been told these are fixed in LV 8.0
See this thread for more details on the bug.
http://forums.ni.com/ni/board/message?board.id=170&message.id=105455&jump=true
Now as far as the constants that are based on the typedef changing, tht is normal behaviour. As Odd_Modem mentioned, doing an explicit bundle by name is the way to handle this. If you use the same "constant" repeatedly in your code, a sub-VI that does the bundling makes your code a lot easier to read.
Here is a code snippet
and the source for that example can be ound in this thread.
http://forums.ni.com/ni/board/message?board.id=170&message.id=148471#M148471
Ben
Message Edited by Ben on 10-29-2005 10:42 AM
10-29-2005 03:44 PM
Thanks for the link, Ben,
Phillip C.'s post seems most helpful. He makes the distinction between object-references and control-references. Looks (to me) like "Make current value default" updates a table of default-values - which are applied sequentially to objects in the cluster (when the user selects "Reinitialize to default value" OR whan a type-def change is detected.) But the defaults-list isn't being updated [correctly] when a cluster-object is removed - so obsolete default-values start getting forced onto a new list of objects. I'd have thought that a "default value" would become a property of (stored "inside") the cluster-object, and, so, follow the object.
Thanks for the work-around! Of course if someone needs the constant/defaults in many places, they would want to use a sub-vi, refer to a global value, or employ some solution to constrain the damage caused by typedef changes.
Regards