RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TypInfo.GetTypeName Function

Returns the name of the type from it's type information record.

Pascal
function GetTypeName(TypeInfo: PTypeInfo): string;
C++
AnsiString GetTypeName(PTypeInfo TypeInfo);

GetTypeName utilises Delphi's RTTI (Run Time Type Information) to return the name of a type as defined in the code.  

TypeInfo is the type information record that describes the type for which the name must be obtained. You can obtain the type information for a type by calling the TypeInfo function in Delphi or the __delphirtti operator in C++. 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!