String Array of Array Java Example
Set, get string , array of array of strings, Java example code
public final static String[][]_arArOfString_1 = {
new String[] {"bla","bla","hello world!"},
new String[] {},
new String[] {},
new String[] {},
new String[] {},
new String[] {}
};
String sOut = _arArOfString_1[0][2]; // hello world!
396LW NO topic_id
AD
Další témata ....(Topics)
C:\documents\workspace\.metadata\.plugins\org.eclipse.core.runtime\.settings\org.eclipse.jdt.ui.prefs
How install Android emulator on PC
//developer.android.com/sdk/installing.html
Download links:
Java Development Kit JDK download
Eclipse download
Android SDK download
//developer.android.com/sdk/installing.html
Download links:
Java Development Kit JDK download
Eclipse download
Android SDK download
Context context = getApplicationContext();
Drawable drawable = context.getResources().getDrawable(R.drawable.my_image);
// convert drawable to bitmap
Bitmap bitmap = ((BitmapDrawable)drawable).getBitmap();
// convert bitmap to drawable
Drawable d = new BitmapDrawable(bitmap);
Android example source code.
Try reboot device.
Start device with start button on side of phone.
Screen will go to light black color.
Long press Start button for menu:
Power off
Reboot
Airplane mode
Reboot item is in same level like Start button.
Click on the screen - (Hear a click)
Now find OK button , it is under Reboot item on right side of screen.
Press OK (Hear a click)
Wait a moment.
If device to do nothing , try short press Start button (sreen will black)
and again to press Start button. If screen go to light black color,
try again find Reboot item as written above.
Start device with start button on side of phone.
Screen will go to light black color.
Long press Start button for menu:
Power off
Reboot
Airplane mode
Reboot item is in same level like Start button.
Click on the screen - (Hear a click)
Now find OK button , it is under Reboot item on right side of screen.
Press OK (Hear a click)
Wait a moment.
If device to do nothing , try short press Start button (sreen will black)
and again to press Start button. If screen go to light black color,
try again find Reboot item as written above.
Definition of ListView in layout main.xml file Android example
Code in Main.java ListView example source code Java Android
<ListView android:id="@+id/idListView"
android:background="#7700CC00"
android:layout_height="wrap_content"
android:layout_width="fill_parent" />
Code in Main.java ListView example source code Java Android
public class Main extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
ListView mlistView = (ListView) findViewById(R.id.idListView);
mlistView.setAdapter(new ArrayAdapter<String>(this,
android.R.layout.simple_list_item_1,
new String[] {"Game", "Help", "Home site"}));
mlistView.setOnItemClickListener(new OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View view,
int position, long id) {
// When clicked, show a toast with the TextView text Game, Help, Home
Toast.makeText(getApplicationContext(), ((TextView) view).getText(),
Toast.LENGTH_SHORT).show();
}
});
}
}
Editace: 2013-12-09 11:04:09
Počet článků v kategorii: 396
Url:string-array-of-array-java-example