Re: an enum question - how to convert enum type to a string?

Discussion in 'Java' started by Roedy Green, Feb 27, 2010.

  1. Roedy Green

    Roedy Green Guest

    On Fri, 26 Feb 2010 08:33:20 -0500, www <> wrote, quoted
    or indirectly quoted someone who said :

    >
    >In my program, I need to get the string "CarModel" from enum CarModel.
    >Is there a way to do it?

    see http://mindprod.com/jgloss/enum.html

    --
    Roedy Green Canadian Mind Products
    http://mindprod.com

    The major difference between a thing that might go wrong and a thing that cannot possibly go wrong is that when a thing that cannot possibly go wrong goes wrong it usually turns out to be impossible to get at or repair.
    ~ Douglas Adams (born: 1952-03-11 died: 2001-05-11 at age: 49)
     
    Roedy Green, Feb 27, 2010
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. guoqi zheng

    convert type string to type guid

    guoqi zheng, Jul 2, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    13,384
    =?Utf-8?B?QmlsbCBCb3Jn?=
    Jul 2, 2005
  2. Replies:
    6
    Views:
    960
    Greg Comeau
    Oct 20, 2005
  3. Eric Sosman
    Replies:
    3
    Views:
    783
    Mayeul
    Feb 26, 2010
  4. Wojtek
    Replies:
    1
    Views:
    504
  5. Lew
    Replies:
    0
    Views:
    541
Loading...

Share This Page