02-23-2011 03:04 AM
Hi
ok, so let me give you some details. Both GOOP4 and GOOP3 have their own code to handle the reference data. This code is partitioned into each class, so each class in an inheritance hierarchy with for example GOOP3 has some specific code to handle the data defined in that class. To make it work during class creation and destruction the child class Create/Destroy calls the parent class Create/Destroy up to the root parent. So the child class expects its parent to be of the same kind, i.e. GOOP3 or GOOP4. The class kernel in GOOP3 that handles reference based data has linked dependencies to its parent kernel (but not vice versa).
When you use our tool features to change inheritance the tool does two things. 1. change the labVIEW class inheritance (same as you did throug the LVclass properties). 2. It relinks the child class code to its new parent class to get Create/desotroy plus class kernels correct.
This is why our tool don't support inheritance between GOOP4 and GOOP3. This is also the reason why it is not a good idea to change class inheritance of GOOP3/GOOP4 classes through trough LVclass properties, the step 2 gets lost.
So, I think this is somehow the background to your experienced problem. I cannot really give you a solution other than the obvious to use only GOOP4 or GOOP3 in an inheritance hierarchy.
I will ask Mike who develops the tool to look at this discussion and see if he has some better work around or fix for you. I understand this post isn't really much help other than as some background info.
Thanks,
Jan
02-23-2011 03:18 AM
Hi guys
What I like to add in this discussion is that you can mix and match different class styles (GOOP3, GOOP4 and Native) in your project, but don't cross the inheritance between the types. Also for the GOOP-classes don't change the inheritance manually, use the tool for this (unless you know what steps are needed to be done manually).
Cheers,
Mikael
02-23-2011 03:20 AM
Mike
I think his problem is the interaction between the GOOP3 child and the persisten design pattern he applied to the GOOP4 parent.
Any tip for him?
Jan
02-23-2011 04:06 AM
Hi
So if I understand your problem, you're having problem keeping the File ref alive.
Any refrences in labview gets released when the VI that CREATED them (Open File, Create Queue, Open TcpIP) becomes Idle.
I've attached a simple GOOP3 dynamic load class example using file reference.
I'm not sure if it helps you, if you can upload your code I can have a look.
Cheers,
Mikael
02-23-2011 04:01 PM
I reverted my base class back to a Goop 3 class so that the inheritance hierarchy is all of the same type (Goop 3). The code is now working again.
Thank you Mikael and Jan for your help.
Best Regards,
Rollin