LAVA 1.0 Content Posted September 19, 2008 Report Share Posted September 19, 2008 I try to use the new functionality of flattening classes to XML but I got an error when I try to Unflatten a class containing another class within it attribute. Is it a bug or a misunderstood? See attach project. Download File:post-6703-1221752759.zip Quote Link to comment
PaulL Posted September 19, 2008 Report Share Posted September 19, 2008 Hmmm... I haven't looked in detail at the issue you are facing, but I did encounter some issues with using LabVIEW classes with the Flatten to XML and Unflatten from XML functions. The CAR for this is CAR# 124834. NI traced that problem, though, to the use of Enums in the class data, not just to having a class within a class (which did work in some simple tests I did). It seems you are encountering a different problem, though. By the way, I think this is the ability to translate LabVIEW class data to XML is a potentially an extremely powerful tool! For instance, we are interested in this as a way to share data with a Java application, and as a way to send data to implement the OOP command pattern (there are other ways to do this, of course). Paul Quote Link to comment
orko Posted September 19, 2008 Report Share Posted September 19, 2008 It seems that Flatten/Unflatten to String works fine with your example. Download File:post-3266-1221768337.vi I'm not sure if you actually needed to flatten to the LabVIEW XML format, but this is a possible workaround if all you needed to do is flatten the class data pass it to another process. Thanks for this example! I was just working on a project that will benefit from flattened class data. Quote Link to comment
LAVA 1.0 Content Posted September 19, 2008 Author Report Share Posted September 19, 2008 QUOTE (orko @ Sep 18 2008, 04:08 PM) It seems that Flatten/Unflatten to String works fine with your example in LV8.6. Thanks for this alternative. I had thought but I assumed that this would be the same behavior. Next time I'll put away my assumption. QUOTE (orko @ Sep 18 2008, 04:08 PM) (haven't tried in 8.5 yet). Flatten/Unflatten classes is a LV8.6 new feature. Quote Link to comment
orko Posted September 19, 2008 Report Share Posted September 19, 2008 QUOTE (pdc @ Sep 18 2008, 01:24 PM) Flatten/Unflatten classes is a LV8.6 new feature. No wonder it seemed like something I hadn't seen before :-) Quote Link to comment
Mike Matthes Posted January 8, 2009 Report Share Posted January 8, 2009 QUOTE (Paul_at_Lowell @ Sep 18 2008, 10:42 AM) Hmmm... I haven't looked in detail at the issue you are facing, but I did encounter some issues with using LabVIEW classes with the Flatten to XML and Unflatten from XML functions. The CAR for this is CAR# 124834. NI traced that problem, though, to the use of Enums in the class data, not just to having a class within a class (which did work in some simple tests I did). It seems you are encountering a different problem, though.By the way, I think this is the ability to translate LabVIEW class data to XML is a potentially an extremely powerful tool! For instance, we are interested in this as a way to share data with a Java application, and as a way to send data to implement the OOP command pattern (there are other ways to do this, of course). Paul Paul - do you recall if this produces error 1527 - "LabVIEW: Attempted to read flattened data of a LabVIEW class that is not currently loaded into LabVIEW."? I'm getting this error trying to convert out of an XML string that was just saved to disk. I certainly have the class loaded in memory - there's an object sitting right next to the unflatten from XML (in fact its wired into that function). I don't think this XML is quite ready for use... Mike Quote Link to comment
Aristos Queue Posted January 8, 2009 Report Share Posted January 8, 2009 This bug has been confirmed in LV 8.6. It has been filed as CAR 139602. Quote Link to comment
Aristos Queue Posted January 15, 2009 Report Share Posted January 15, 2009 QUOTE (Aristos Queue @ Jan 7 2009, 05:03 PM) This bug has been confirmed in LV 8.6. It has been filed as CAR 139602. This bug will be fixed in the upcoming bug-fix release of LabVIEW. Quote Link to comment
Aristos Queue Posted January 15, 2009 Report Share Posted January 15, 2009 QUOTE (Aristos Queue @ Jan 7 2009, 05:03 PM) This bug has been confirmed in LV 8.6. It has been filed as CAR 139602. This bug will be fixed in the upcoming bug-fix release of LabVIEW. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.