Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Public enum list

Status
Not open for further replies.

Bastel

Programmer
Mar 25, 2002
11
DE
Hi there,
Here is my problem:
i have in class a public type
public type enum my_tags
val1 = &&H10F&
val2 = &H14F&
val3 = &H21F&
etc....
end type
does someone know howto go trough the elements
and get both values and description
e.g.
should be somehow convertet to an array
for i = 0 to my_tags.count (count doesn't exist)
Descript= my_tags(i).description
Value= my_tags(i).value
next i


Kind Regards Bastel
 
There is no way to do this with enumerated types. You will need to uses classes if you require this functionality.

Chris Dukes
 
Au contraire. It is quite possibel to list the names and values of a public enum in a class.

I'm away from my normal development box at the moment, so don't have immediate access to the necessary code. However, it merely requires a reference to the (redistributable)TypeLib Information library, and a minor amount of code.

I'll try and dig my version out when I get the chance.
 
Au contraire. It is quite possible to list the names and values of a public enum in a class.

I'm away from my normal development box at the moment, so don't have immediate access to the necessary code. However, it merely requires a reference to the (redistributable)TypeLib Information library, and a minor amount of code.

I'll try and dig my version out when I get the chance.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top