Found 1966 Articles for Apps/Applications

How to get the duplicates values from Arraylist and then get those items in another Arraylist in Android?

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:25

939 Views

This example demonstrate about How to get the duplicates values from Arraylist and then get those items in another Arraylist.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken listview to show duplication list items from array list.Step 3 − Add the following code to src/MainActivity.javapackage com.example.andy.myapplication; import android.os.Bundle; import android.support.v7.app.AppCompatActivity; import android.widget.ArrayAdapter; import android.widget.ListView; import java.util.ArrayList; import java.util.HashSet; import java.util.Set; public class MainActivity extends AppCompatActivity ... Read More

How to get phone number in android?

Jennifer Nicholas
Updated on 30-Jul-2019 22:30:25

4K+ Views

This example demonstrate about How to get phone number in android.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml.     In the above code, we have taken text view. When user open application, Phone number going to append on textview.Step 3 − Add the following code to src/MainActivity.java.package com.example.andy.myapplication; import android.Manifest; import android.content.Context; import android.content.pm.PackageManager; import android.os.Build; import android.os.Bundle; import android.support.annotation.RequiresApi; import android.support.v4.app.ActivityCompat; import android.support.v7.app.AppCompatActivity; import android.telephony.TelephonyManager; import android.widget.TextView; import ... Read More

How to update ui from Intent Service in android?

Nitya Raut
Updated on 30-Jul-2019 22:30:25

2K+ Views

Before getting into example, we should know what Intent service is in android. Intent Service is going to do back ground operation asynchronously. When user call startService() from activity , it doesn’t create instance for each request. It going to stop service after done some action in service class or else we need to stop service using stopSelf().This example demonstrate about How to update ui from Intent Service.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to ... Read More

How to start intent service for every 10 sec’s in android?

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:25

1K+ Views

Before getting into example, we should know what Intent service is in android. Intent Service is going to do back ground operation asynchronously. When user call startService() from activity , it doesn't create instance for each request. It going to stop service after done some action in service class or else we need to stop service using stopSelf().This example demonstrate about How to start intent service for every 10 sec’s.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following ... Read More

How to share intent from intentservice in android?

Nitya Raut
Updated on 30-Jul-2019 22:30:25

295 Views

Before getting into example, we should know what Intent service is in android. Intent Service is going to do back ground operation asynchronously. When user call startService() from activity , it doesn’t create instance for each request. It going to stop service after done some action in service class or else we need to stop service using stopSelf().This example demonstrate about How to share intent from intentservice.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml. ... Read More

How to run continues thread in android?

Nitya Raut
Updated on 30-Jul-2019 22:30:25

434 Views

Before getting into an example, we should know what thread in android is. Threads are generic processing tasks that can do most things, but one thing they cannot do is update the UI.This example demonstrates about How to run continues thread in android.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to res/layout/activity_main.xml. In the above code, we have taken textview. When the user clicks on textview, it will start continues thread ... Read More

How to refresh Activity when IntentService is finished in android?

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:25

507 Views

Before getting into the example, we should know what Intent service is in android. Intent Service is going to do background operation asynchronously. When user call startService() from activity, it doesn’t create an instance for each request and it going to stop service after done some action in service class or else we need to stop service using stopSelf().This example demonstrates How to refresh Activity when IntentService is finished.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code ... Read More

How to create DigitalSpeedDashboard in android?

Jennifer Nicholas
Updated on 30-Jul-2019 22:30:25

84 Views

This example demonstrate about How to create DigitalSpeedDashboard in android.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Open build.gradle and add library dependency as shown below –apply plugin: 'com.android.application' android {    compileSdkVersion 28    defaultConfig {       applicationId "com.example.andy.myapplication"       minSdkVersion 19       targetSdkVersion 28       versionCode 1       versionName "1.0"       testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"    }    configurations {       cleanedAnnotations       compile.exclude ... Read More

How to update continues ui from Intent Service in Android?

Nitya Raut
Updated on 30-Jul-2019 22:30:25

420 Views

Before getting into example, we should know what is Intent service in android. Intent Service is going to do back ground operation asynchronously. When user call startService() from activity , it doesn’t create instance for each request and it going to stop service after done some action in service class or else we need to stop service manually by using stopSelf().This example demonstrate about How to update continues ui from Intent Service.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add ... Read More

Android stop specified IntentService?

Vrundesha Joshi
Updated on 30-Jul-2019 22:30:25

444 Views

Before getting into the example, we should know what Intent service is in android. Intent Service is going to do background operation asynchronously. When user call startService() from activity, it doesn’t create the instance for each request and it going to stop service after done some action in service class or else we need to stop service manually by using stopSelf().This example demonstrates about Android stop specified IntentService.Step 1 − Create a new project in Android Studio, go to File ⇒ New Project and fill all required details to create a new project.Step 2 − Add the following code to ... Read More

Advertisements