×

Discussion Board

Results 1 to 7 of 7
  1. #1
    Registered User
    Join Date
    May 2010
    Posts
    214

    Unhappy doubt about items in j2me plz help me

    how to add the following choices as items like item,item1,item2,item3 and so on without using choicegroup in j2me

    technology = new ChoiceGroup("Select Technology Which You Know", Choice.MULTIPLE);
    technology.append("JAVA", null);
    technology.append("J2ME", null);
    technology.append("J2EE", null);
    technology.append("JSF", null);
    form.append(technology);

  2. #2
    Super Contributor
    Join Date
    Apr 2007
    Posts
    2,708

    Re: doubt about items in j2me plz help me

    I guess you could make a ChoiceGroup for every single one of them ?
    Which would create one "item" for every single entry to be appended to the form...
    Or isn't that what you are trying to ask ?

  3. #3
    Super Contributor
    Join Date
    Mar 2008
    Location
    The Capital of INDIA
    Posts
    4,328

    Re: doubt about items in j2me plz help me

    Quote Originally Posted by kumarv75 View Post
    how to add the following choices as items like item,item1,item2,item3 and so on without using choicegroup in j2me

    technology = new ChoiceGroup("Select Technology Which You Know", Choice.MULTIPLE);
    technology.append("JAVA", null);
    technology.append("J2ME", null);
    technology.append("J2EE", null);
    technology.append("JSF", null);
    form.append(technology);
    What actually you wanna develop?
    A drop down list or something smiler to this..?
    What is the problem with the choicegroup?
    Thanks with Regards,

    R a j - The K e r n e l


    Join Delhi-NCR Nokia Developer's Community,

  4. #4
    Regular Contributor
    Join Date
    Mar 2005
    Location
    Hamburg, Germany
    Posts
    284

    Re: doubt about items in j2me plz help me

    If you don't want to use a ChoiceGroup (why?)
    than you can use StringItem with the appearance-mode of Button:

    Code:
    item1 = new StringItem("Java", null, Item.BUTTON);
    item1.addCommand(...);
    item1.setItemCommandListener(this);
    form.append(item1);

  5. #5
    Registered User
    Join Date
    May 2010
    Posts
    214

    Unhappy Re: doubt about items in j2me plz help me

    I need to use an item and create a choice instead of using a choice group.............................

  6. #6
    Registered User
    Join Date
    May 2010
    Posts
    214

    Unhappy Re: doubt about items in j2me plz help me

    Quote Originally Posted by internetlabor View Post
    If you don't want to use a ChoiceGroup (why?)
    than you can use StringItem with the appearance-mode of Button:

    Code:
    item1 = new StringItem("Java", null, Item.BUTTON);
    item1.addCommand(...);
    item1.setItemCommandListener(this);
    form.append(item1);
    then can we write like this

    item = new Item("Select Technology Which You Know", Choice.MULTIPLE);

  7. #7
    Super Contributor
    Join Date
    Apr 2007
    Posts
    2,708

    Re: doubt about items in j2me plz help me

    As you can see from the Javadoc :
    http://java.sun.com/javame/reference...cdui/Item.html

    There is no Constructor available for the Item class (after all it's an Abstract class), this is a superclass for other Classes like ChoiceGroup, ImageItem, Textfield etc...

Similar Threads

  1. Acessing voice channel using J2ME
    By diegomello in forum VoIP
    Replies: 1
    Last Post: 2008-10-21, 15:57
  2. Replies: 5
    Last Post: 2008-10-09, 05:38
  3. Porting BlackBerry: Carbide & J2ME Comparison.
    By skynetchris in forum Symbian
    Replies: 0
    Last Post: 2008-05-22, 07:09
  4. doubt in j2me polish.....
    By abhilashm in forum Mobile Java General
    Replies: 0
    Last Post: 2008-01-16, 10:24
  5. need urgent guidance on j2me
    By cogni_niru in forum Mobile Java General
    Replies: 1
    Last Post: 2005-11-13, 15:02

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×