Enum title in string

To add comments, please log in or register
Erwann Pannerec
264
Erwann Pannerec  

Hi all,


Is there any way to get easily the string value of an ENUM parameter ?


For exemple, I create an input parameter like that :

input ENUM_SYMBOL_INFO_DOUBLE var1 = SYMBOL_ASK;

And I would like to have a string variable which contains the title of the ENUM parameters choosen by the user :

string title = ???;


Thank you !

Ghen

Taras Slobodyanik
29025
Taras Slobodyanik  

try this

string  EnumToString( 
   any_enum  value      // any type enumeration value 
   );
Erwann Pannerec
264
Erwann Pannerec  
Taras Slobodyanik:

try this

It works !


Thank you :)

To add comments, please log in or register