04-28-2021 04:27 AM
Hi,
Are you changing the inheritance using the G# IDE or are you changing it using the LabVIEW tools?
You should be doing everything through the IDE (right click > g# IDE) this includes making you classes.
Depending on what you want to do, you may also need to define your class as 'abstract' when creating it.
04-28-2021 06:33 AM
All my operation Using G#IDE
04-29-2021 06:16 AM
This is the change-inheritance bug in LV2020 I explained in https://forums.ni.com/t5/G/Inheritance-Error/td-p/4086662
The solution is in that thread.
04-29-2021 07:39 AM
it seems that not this bug。
04-29-2021 11:52 PM
"
1. create queue_class Inherit from G#
2.create UI_class Inherit from G#
3. change UI_class Inherit to queue_class
4.create a test vi, this vi content is create a UI_class ,then call dequeue method it occur errors ."
I did exactly that and the inheritance error is the only error I get. Please post code that can produce the error you are seeing. The code you posted throws an error but for a completely different reason than what you are explaining, and the reason for that error is already explained and has nothing to do with G#. Is that the error you are referring to? Are you getting a dialog from the LabVIEW IDE or an error code on the error wire? What error code is it?
05-05-2021 07:53 PM
8D_NAE3E%]BT{66Z_OK`5I0.png
1. create queue_class Inherit from G#
2.create UI_class Inherit from G#
3. change UI_class Inherit to queue_class
Until the third step, Does UI_create VI include Queue_Create Vi?
05-06-2021 01:08 AM
@yanzhanglin wrote:
8D_NAE3E%]BT{66Z_OK`5I0.png
1. create queue_class Inherit from G#
2.create UI_class Inherit from G#
3. change UI_class Inherit to queue_class
Until the third step, Does UI_create VI include Queue_Create Vi?
Ah, I see what you mean now. When changing inheritance from G#Object, the Create-method of the base-class is not inserted. It has likely been like this since forever and no-one was bothered enough by it to report it.
The workaround is to insert it yourself, as you have found out.
I have added this issue to the issue-list for G# and have talked to the main developer about it and hopefully it will be implemented in the next version of G#.
05-06-2021 02:48 AM
I think deep clone method
yanzhanglin_0-1620286964809.png
and when we create property,we can create all property at one time,
yanzhanglin_1-1620287051132.png
and if we change objectAttribute members,we can just update property,it will change all create property VI。