06-05-2014 04:40 AM
Hi all,
I often use packed libraries to distribute my software.
My problem is the following:
I save a LabVIEW object of a class (MyClass) that is not included in a packed library using "Write datalog" (for example saved file is MyObject.dat).
If I load MyObject.dat using "Read Datalog" but using "MyCLass" saved in packed library as "Record type", Read Datalog generates an error or anyway loaded data is inconsistent.
In other word, if I save an object using as "Record Type" MyClass not included in a packed library and then I load saved file using the MyClass included in a packed library, file cannot be loaded.
Can you help me?
Thank all
06-05-2014 09:27 AM
I think you are running into an issue created by namespacing.
Point is, that lvlib as well as lvlibp create a level of namespacing:
I would expect that level of namespaces being part of the datalog file.
So essentially, if the class is not encapsulated in the very same namespace when reading in which it was written, it should fail with exactly the error you are describing.
Norbert
06-06-2014 05:02 AM
Thank you Norbert_B.
So, isn't there a workaround to avoid this problem?
Thanks
06-06-2014 06:25 AM - edited 06-06-2014 06:26 AM
There is a solution: The reading program must have the very same setup as the writing application.
Norbert
EDIT: Or drop datalog files and serialize your data while writing and reconstruct it during reading....