List


This code use to make List in j2me
Kode dibawah ini digunakan untuk membuat List di j2me

import javax.microedition.lcdui.Display;
import javax.microedition.lcdui.List;
import javax.microedition.midlet.*;

/**
* free to distribute but forbiden to delete this statement
* @author b1ms.wordpress.com
* ym : thats_myboy@yahoo.com
* “share code for free”
*/
public class CreatingList extends MIDlet {
private Display display;
private List list;

public CreatingList() {
display = Display.getDisplay(this);
list = new List(“Select one”, List.EXCLUSIVE);
list.append(“isi 1”, null);
list.append(“isi 2”, null);

}

public void startApp() {
display.setCurrent(list);
}

public void pauseApp() {
}

public void destroyApp(boolean unconditional) {
}

}

download source

Running program

Untuk bentuk list yang lain
For the different list

list = new List(“Select one”, List.EXCLUSIVE);

Dapat diganti
Can change with

list = new List(“Select one”, List.IMPLICIT);

atau
or

list = new List(“Select one”, List.MULTIPLE);

smoga bermanfaat

hope useful for u

Iklan
Ditulis dalam dasar, j2me. Tag: , . Leave a Comment »

tinggalkan pesan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout / Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout / Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout / Ubah )

Foto Google+

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s

%d blogger menyukai ini: