Derived TDataStd_UAttribute doesn't work


I create a class which derived from TDataStd_UAttribute, I can add it as an attribute to a TDF_Label, but when I couldn't get it by FindAttribute, dump the label, I find the GUID became 0000-000-.... , i.e. all zero. But in deed I have a valid, guidgen generated GUID.

Any suggestion will be highly appreciated.


Patrik Mueller's picture


I haven't use this class for now. Do you have initialized your class with the right GUID (setting myID via constructor or SetID)?
Apart from that check your set functions for the label since TDataStd_UAttribute wants two variables in its Set method.

Lets look.

Patrik Müller

fhchina's picture

Hi, Patrik:

I lost SetID, Now problem is solved. thank you.