Hafedh TRIMECHE 1 Posted December 13, 2020 Hello, Is there a function GetBaseType which returns the Base Type of a sub-type? type TCustomDateTime = type TDateTime; GetBaseType(TypeInfo(TCustomDateTime)) would return TypeInfo(TDateTime). Best regards. Share this post Link to post
Guest Posted December 14, 2020 (edited) for Class and Interface, for example: see in Help System: System.Rtti.TRttiType.BaseType The value of BaseType depends on the actual reflected type. In the case of types that support inheritance (such as classes or interfaces), BaseType represents the ancestor. For all other cases, BaseType simply returns nil. using RTTI to get info: https://stackoverflow.com/questions/7836880/how-can-i-distinguish-tdatetime-properties-from-double-properties-with-rtti <--- I think that answer you! Edited December 14, 2020 by Guest Share this post Link to post