Skip to Content

SetPropertyComparable - available parameters

Hi all,

We are trying to use the Comparison Helper to compare two LDM models and extract the changes into an Excel file. This works fine, but now we would like to exclude an extended attribute (metaclass Entity Attribute) from the comparison. For this we use the method SetPropertyComparable, but we cannot find the correct syntax for this, hence, what to use as ClssName and PropName.

We have two models, mdl1 and mdl2 and would like the exclude the extended attribute "Catalogue" from the comparison. We tried many things, but it doesn't seem to work:

Set Cmpr = mdl1.CreateComparisonHelper(mdl2)
Cmpr.SetClassComparable "*", TRUE
Cmpr.SetPropertyComparable "EntityAttribute", "ExtendedAttributes.Catalogue", FALSE

For id = 0 To Cmpr.GetDifferencesCount()
Cmpr.GetDifferenceInformation id, DiffKind, OldObject, NewObject, MemberPublicName, OldValue, NewValue
If DiffKind = mrg_modified Then
output "Old:" OldObject + ", new:" + NewObject
End If

Could someone please tell us what the correct syntax is to do this?



Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Jan 25, 2017 at 04:20 PM

    Have you tried qualifying "ExtendedAttributes.Catalogue" with the Library and Class Name?

    Add comment
    10|10000 characters needed characters exceeded

  • Jan 31, 2017 at 09:40 AM

    Thanks for your answer. I don't understand exactly what you mean. The arguments SetPropertyComparable have to be public names. For entity attributes this is EntityAttribute. We have tried also using the class name, like cls_xxx but this doesn't seem to work.

    We believe the first argument (describing the class name) should be ok, since it works if we write for instance SetPropertyComparable "EntityAttirbute", "DataType", False. We are, however, in doubt about the second argument, since this is not a standard property of the metaclass, but an extended attribute. We are not sure how to address this extended attribute in the extension. An entity attribute hast the property ClassPublicName, but this property is not available for extended attributes. It is also possible to have more than one extension with the same extended attribute, so perhaps we also need the extension name in the argument. However, you can get the extended attribute value directly from the attribute by using GetExtendedAttribute, so perhaps you don't need to "navigate" through the extension.

    Add comment
    10|10000 characters needed characters exceeded