Custom ListView Android

Android supports the feature of customizing a ListView. To add the content from a data source, the Adapter classes are used by the custom ListView, just like a simple ListView. The data source can be a string array, array, database, etc. The data between an AdapterViews and other Views is 4bridged by the Adapter./ Example … Read more

ListView Android

To include a group of items to be displayed in a scrollable list, the Android ListView is used. It is a view. By importing the android.widget.ListView class, the ListView is implemented. It does not use other scroll views as it is a default scrollable. The Adapter classes are used by the ListView to add the … Read more

AutoCompleteTextView Android

To complete the words based on the reserved words, the Android AutoCompleteTextView is used in Android. Thus it is not required to write all the characters of the word. It is an editable text field. A list of suggestions is thus displayed in a drop-down menu. At a time only one suggestion or value can … Read more

Spinner Android

Android supports various widgets such as Android Button, Android Toast, Custom Toast, Android ToggleButton, Android CheckBox, Android AlertDialog, Spinner, AutoCompleteTextView, RatingBar, DatePicker, TimePicker, and ProgressBar. The Spinner is one of these unique and important Android Widgets. Much like a combo box of AWT or Swing, the Android Spinner is used to display multiple options to … Read more

AlertDialog Android

To display the dialog message with buttons like OK, Yes, No and Cancel, the AlertDialog is used in Android. To interrupt to ask the user about the choice to continue or discontinue, the AlertDialog is used. There are three regions: title, content area, and action buttons in Android AlertDialog which is a subclass of Dialog … Read more

Custom CheckBox Android

To facilitate the creation of the CheckBoxes, Android provides the android.widget.CheckBox class. Instead of using the default settings, we can also customize the UI of view elements in Android. Thus, different images of the checkbox can also be added to the layout. The CheckBox in Android can be understood as a type of two-state button. … Read more

CheckBox Android

The CheckBox in Android can be understood as a type of two-state button. Here, the two-state means that it can be either checked or unchecked. Checkboxes can be used to serve various purposes such as selecting the hobbies of a user and to activate/deactivate a specific action. The CompoundButton class in Android has a subclass … Read more

Custom RadioButton Android

A custom radio button can also be implemented in Android, other than the default user interface of android RadioButton. It is usually used to create a more attractive user interface. Example of Custom RadioButton: activity_main.xml: (File: activity_main.xml) <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" tools:context=".MainActivity">   <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Select One" android:textStyle="bold" android:layout_marginLeft="10dp" … Read more

Dynamic RadioButton Android

The Radio Button in android can also be created programmatically or dynamically, other than creating it through drag and drop from the palette. With a single click, we can convert an unchecked radio button to a checked radio button. The user cannot mark a checked radio button to unchecked. It is generally used with RadioGroup. … Read more

Android RadioButton

RadioButton can be understood as a type of two-states button. Here, the two-states means that it can either be checked or unchecked. With a single click, we can convert an unchecked radio button to a checked radio button. The user cannot mark a checked radio button to unchecked. It is generally used with RadioGroup. Several … Read more