Navigation:  Functions > Enum Functions >

DaoEnum2Str() function

Previous pageReturn to chapter overviewNext page

Purpose

Translate a Enum value to a string

 

Parameters

liValueEnum value that has to be converted
aEnum2 dimensional Array as returned by one of the Dao...Enum() functions
lCheckAllCheck all of the values in the array, and concatinate into one string

 

Returns

A string value

 

Description

With this function you can translate a Enum value into a string. Sometimes (for example with permissions and relation types) different values of an enum are combined into one Long integer by using the binary OR. The 3rd parameter deterines if this function should check all the values of the array, and return a string with all the values that have been combined.

 

Example

 

oFld := oTd:Fields:[Item,1]

// display the field type and all of the field attributes

? DaoEnum2Str(oFld:Type, DaoFieldTypeEnum(),FALSE)

? DaoEnum2Str(oFld:Attributes, DaoFieldAttributeEnum(),TRUE)