Skip to content

StructName

Include: Use System\Reflection.pkg

See Also: StructTypeOf, StructMemberCount, StructMemberType, StructMemberName, StructMember, StructSetMember

Purpose

Returns the struct type name for a struct metadata handle.

Syntax

Function StructName Global Handle hStruct Returns String

Arguments

hStruct : Struct metadata handle.

Returns

The struct type name.

Behavior

Invalid or zero handles raise a DataFlex error.

Example

Struct tCustomer
    Integer iId
    { Name="name" }
    String sName
End_Struct

tCustomer tCustomerValue
Handle hStruct

Move 1 to tCustomerValue.iId
Move "Ada" to tCustomerValue.sName
Get StructTypeOf tCustomerValue to hStruct

String sStructName
Get StructName hStruct to sStructName