In this example creating some UI elements on screen on run time. Creating textview , buttons dynamically and creating onclick listener for buttons. After click on button show index(id).
In This example creating Notification Alerts with the use of NotificationManager.
Some times we have requirement to show alert user from background services or from broadcast reciever then best way to notify user by Notification Alert
In This example creating a simple repeating alarm system with the use of AlarmManager. Alarm will start after each 2 mins.
Steps :
1. Using AlarmManager class to repeating and called a PendingIntent after each 2 min. 2. Call a media file on PendingIntent and start media file. 3. So after each 2 min AlarmManager will call PendingIntent a media file start.
In this example creating time picker. time picker is used for selecting the time of day, in either 24 hour or AM/PM mode. The hour, each minute digit, and AM/PM (if applicable) can be conrolled by vertical spinners.
In This example creating checkbox and listener to listen checkbox click and show selected checkbox value.
Create a CheckBox in your layout. Checkbox options allows the user to select multiple items, each checkbox is managed separately and you must register a click listener for each one.
In this example showing Radio buttons with a radio group and determining which radio button is selected.
Radio buttons are normally used together in a RadioGroup. When several radio buttons live inside a radio group, checking one radio button unchecks all the others.