I starting intent service in onCreate() method in subclass of Application class. But it is called when app is opened the first time. It should not calling on every time the app is opened. It does even not work when I kill the background process. And my observation its working in galaxy note but not in samsung s duos, please help me.
public class MyApp extends Application {
@Override
public void onCreate() {
Toast.makeText(this.getApplicationContext(), "APPLICATION", Toast.LENGTH_LONG).show();
context=this.getApplicationContext();
if (!ContactUtiles.isFileExit()) {
createDatabase(Opration.NOT_FOR_DELTA);
if (DBConstants.LOGD) {Log.d(TAG, DBConstants.DB_NOT_EXIST);}
}
super.onCreate();
}
}