Page 1 of 1

Reverse enumeration lookup

Posted: Fri Aug 14, 2009 1:20 pm
by Trond

Code: Select all

Enumeration 0, EnumName
  #Test
  #Toast
  #Debugging
EndEnumeration

A = #Debugging
Show.s = ConstantString(A, EnumName)
; Show = "#Debugging"
Handy for debugging and logging purposes. Of course, the constant names would not be included in the executable if ConstantString() was not used with that EnumName.