Android Examples
Login / Register
Android Examples
  • Home
  • Android
  • NEWS
  • Java
  • Faq
  • Algorithms
  1. Home
  2. ANDROID
  3. Android Basics
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
alarmmanager_main

Create Repeating Alarm Start After Each 2 Minutes Create Repeating Alarm Start After Each 2 Minutes

May 30 2013 631925 by admin Download Source Code

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.

Read More
screen sleep captured

Screen Wake Sleep Event Listner Service - Android Example Screen Wake Sleep Event Listner Service - Android Example

Apr 01 2013 631967 by admin Download Source Code

In this example broadcasting screen wake / sleep event with a service.

Some times we  have requirement to make less battery consumption then you can stop your services when phone is going to sleep mode and again start your services when phone is going to wake.

 

Steps :

   1. Create a service inside main activity to get screen wake / sleep broadcast events.
   2. Create a broadcast receiver inside service to get screen wake / sleep events.
   3. Send screen wake/sleep value from broadcast receiver to Service.

Read More
Scan_Wifi_Connections_3

Scan wifi connections or Get number of available wifi connections Scan wifi connections or Get number of available wifi connections

Mar 26 2013 631930 by admin Download Source Code

In this example scaning for number of available wifi connections , Creating a broadcast receiver which will called when number of wifi connections changed.

 

 

Read More
date_picker_main_show_current_date1

In this example creating a date picker to pick day month year of date. In this example creating a date picker to pick day month year of date.

Mar 26 2013 631901 by admin Download Source Code

In this example creating a date picker to pick day , month , year of date.

Read More
Submit_button_click_on_dialog

Custom Dialog - Android Example Custom Dialog - Android Example

Mar 05 2013 632038 by admin Download Source Code

In this example creating a custom dialog with image,text and button.

Dialog is like a popup window to show some options to users(options like accept/decline).

Using class android.app.Dialog to create dialog.

Using dialog.xml file to create custom dialog layout.

Read More
Showing custom toast alert

Custom Toast Alert - Android Example Custom Toast Alert - Android Example

Mar 04 2013 631929 by admin Download Source Code

In this example creating a custom toast alert with one image and text.

Toast alert is a notification message that display for certain amount of time, and automtaically fades out after set time.

Use it to show alert message to user.
Use it for debugging your application.

android.widget.Toast class used to create toast alert message.
 

Read More
Select time picker time

Time Picker With AM_PM Values - Android Example Time Picker With AM_PM Values - Android Example

Mar 04 2013 631922 by admin Download Source Code

In this example creating time picker with 12 hours format with AM/PM values.

android.widget.TimePicker class to create time picker.

Use OnTimeChangedListener to get time picker event.

Read More
Showing_timepicker_with_current_time

Time Picker Basics Part 1 - Android Example Time Picker Basics Part 1 - Android Example

Mar 04 2013 631883 by admin Download Source Code

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.

Read More
Select Spinner item

Custom Spinner With Image And Text - Android Example Custom Spinner With Image And Text - Android Example

Mar 01 2013 631997 by admin Download Source Code

In this Example creating custom spinner with one image and two texts.

After spinner item selection showing selected item text on screen.

Steps :

       1.  Create Model (SpinnerModel.java) to store data for each spinner row.
       2.  Create a ArrayList to store Model (SpinnerModel.java) objects.
       3.  Store data in Models and Store Model objects in Arraylist.
       4.  Pass Model object Arraylist to custom adapter.
       5.  Custom Adapter use Arraylist data (Model Objects) and create rows for Spinner.
       6.  Create listener for Spinner and show spinner item selected values on activity.

Read More
Uploading file on server

Upload File To Server - Android Example Upload File To Server - Android Example

Feb 28 2013 632483 by admin Download Source Code

In this example uploading an image from sdcard to web server.

Steps :

      1.  place an image on sdcard.
      2.  place sdcard image path and image name in UploadToServer.java. ( see below )
      3.  create a php script (UploadToServer.php) at server. ( see below )
      4.  place php script path in UploadToServer.java. ( see below )
      5.  create folder name uploads on server where you have placed php script.
      6.  give permission 777 (read/write/execute) to uploads folder.

Read More
Showing spinner item data

Spinner Basics - Android Example Spinner Basics - Android Example

Feb 28 2013 631923 by admin Download Source Code

In this example creating a simple spinner (Dropdown list).

Creating listener for spinner item selection and showing selected option in alert.

Creating listener for button to show selected spinner item.

Read More
Custom checkbox checked state on screen

Custom Checkbox With The Use Of Selectors And Shapes Custom Checkbox With The Use Of Selectors And Shapes

Feb 25 2013 631954 by admin Download Source Code

In this example creating a checkbox and using selectors and shapes to give custom look.

Using selectors to call checkbox checked state xml and unchecked state xml.

Using xml file to create shape with the use of gradient,stroke tags to give custom look for checkbox checked and unchecked state.

Read More
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6

Categories

  • Android Basics (71)
  • Android Advanced (8)
  • Projects (1)

Tags

ANDROID
  • INSTALLATION
  • BEGINNER
  • SQLite
  • LAYOUTS
  • GUI
  • THREAD
  • BROADCAST RECEIVER
  • LISTVIEW
  • GPS
  • CONTACTS
  • XML / JSON
  • WEBVIEW
  • SHARED PREFERENCES
  • CONTENT PROVIDER
  • SERVICE
  • CAMERA
  • FILE UPLOAD
  • CUSTOM
  • WIFI
  • CALL
  • SMS
  • WEBSERVICE
  • ANIMATION
  • AUTOCOMPLETE
  • ACCELEROMETER
  • NOISE
  • MVC
  • GCM
  • FACEBOOK

Top Downloads

Open File Chooser With Camera Option In Webview File Option Open File Chooser With Camera Option In Webview File Option
Feb 03, 2014 671496
Facebook Integration - Android Example Facebook Integration - Android Example
Jan 13, 2016 670839
Android Session Management Using SharedPreferences - Android Example Android Session Management Using SharedPreferences - Android Example
Jan 19, 2014 670638
Show Loader To Open Url In WebView - Android Example Show Loader To Open Url In WebView - Android Example
Dec 24, 2013 670544
Android SharedPreferences Basics Android SharedPreferences Basics
Dec 28, 2013 670477
Play Video File - Android Example Play Video File - Android Example
Nov 09, 2013 669918
Android Push Notifications using Google Cloud Messaging GCM Android Push Notifications using Google Cloud Messaging GCM
Oct 05, 2013 633194
Upload File To Server - Android Example Upload File To Server - Android Example
Feb 28, 2013 632483
Incomming SMS Broadcast Receiver - Android Example Incomming SMS Broadcast Receiver - Android Example
Feb 04, 2013 632410
How To Make HTTP POST Request To Server - Android Example How To Make HTTP POST Request To Server - Android Example
Feb 06, 2013 632305
Android Examples

Founder of Android Example.com, love Java and open source stuff. Follow him on Twitter, or befriend him on Facebook.

Email: info@androidexample.com

Follow Us

Information

  • About Us
  • Terms & Conditions
  • Privacy Policy
  • Contact Us

My Account

  • My Account
  • My Questions

Sign Up to Our Newsletter

Sign up our newsletter and get exclusive deals you will not find anywhere else straight to your inbox!

Features

  • Java Blogs
  • News
  • Faqs

© 2025 AndroidExample All Rights Reserved.

This website uses cookies to ensure you get the best experience on our website. For more information Learn about cookies