Click here to Skip to main content
15,913,055 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: database store! Pin
Mike Ellison12-Jan-07 12:17
Mike Ellison12-Jan-07 12:17 
AnswerRe: database store! Pin
Michael P Butler13-Jan-07 8:59
Michael P Butler13-Jan-07 8:59 
QuestionStore in TXT Pin
ADY00712-Jan-07 9:14
ADY00712-Jan-07 9:14 
AnswerRe: Store in TXT Pin
Not Active12-Jan-07 9:22
mentorNot Active12-Jan-07 9:22 
GeneralRe: Store in TXT Pin
ADY00712-Jan-07 11:24
ADY00712-Jan-07 11:24 
QuestionEnum [modified] Pin
shapper12-Jan-07 8:36
shapper12-Jan-07 8:36 
AnswerRe: Enum Pin
Not Active12-Jan-07 9:20
mentorNot Active12-Jan-07 9:20 
GeneralRe: Enum Pin
shapper12-Jan-07 13:57
shapper12-Jan-07 13:57 
Hello,

I have the following:

' Loop through each color enumeration name
For Each color As Color In [Enum].GetNames(GetType(Color))

Dim name As String = MyF(color, Thread.CurrentThread.CurrentCulture)

Dim index As Integer = CType(color, Enumeration.District)

Response.Write("Name: " & name & " | Index: " & index.ToString & "<br />")

Next

I think this is working but I am not sure if this is the best way to solve this.

Note: MyF is a function with a Select Case block which returns a string giving a enum element and a culture. I need this.

However, I now need to get the text of an element by giving its index.

For example, get "Red" when I say 1.

Could someone help me out?

Thanks,
Miguel

GeneralRe: Enum Pin
Not Active12-Jan-07 14:09
mentorNot Active12-Jan-07 14:09 
QuestionGridview Question vb.net VS2005 Pin
Jonathan Snyder12-Jan-07 7:23
Jonathan Snyder12-Jan-07 7:23 
AnswerRe: Gridview Question vb.net VS2005 Pin
minhpc_bk12-Jan-07 21:20
minhpc_bk12-Jan-07 21:20 
GeneralRe: Gridview Question vb.net VS2005 Pin
Jonathan Snyder15-Jan-07 3:35
Jonathan Snyder15-Jan-07 3:35 
GeneralRe: Gridview Question vb.net VS2005 Pin
minhpc_bk15-Jan-07 4:26
minhpc_bk15-Jan-07 4:26 
GeneralRe: Gridview Question vb.net VS2005 Pin
Jonathan Snyder15-Jan-07 4:44
Jonathan Snyder15-Jan-07 4:44 
GeneralRe: Gridview Question vb.net VS2005 Pin
Jonathan Snyder15-Jan-07 5:17
Jonathan Snyder15-Jan-07 5:17 
GeneralUsing a Different Base Class Pin
Jonathan Snyder16-Jan-07 4:27
Jonathan Snyder16-Jan-07 4:27 
GeneralRe: Using a Different Base Class Pin
minhpc_bk16-Jan-07 13:41
minhpc_bk16-Jan-07 13:41 
GeneralRe: Using a Different Base Class Pin
Jonathan Snyder17-Jan-07 1:53
Jonathan Snyder17-Jan-07 1:53 
QuestionText box with sqlcommand in VB2005 Pin
VB_Student12-Jan-07 7:17
VB_Student12-Jan-07 7:17 
AnswerRe: Text box with sqlcommand in VB2005 Pin
minhpc_bk12-Jan-07 21:27
minhpc_bk12-Jan-07 21:27 
QuestionHigh memory consumption Pin
Jon Sagara12-Jan-07 5:00
Jon Sagara12-Jan-07 5:00 
AnswerRe: High memory consumption Pin
led mike12-Jan-07 5:26
led mike12-Jan-07 5:26 
GeneralRe: High memory consumption Pin
Jon Sagara12-Jan-07 5:35
Jon Sagara12-Jan-07 5:35 
GeneralLove for ATLAS! Pin
Bulky Fellow12-Jan-07 4:50
Bulky Fellow12-Jan-07 4:50 
GeneralRe: Love for ATLAS! Pin
ednrgc12-Jan-07 5:48
ednrgc12-Jan-07 5:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.