Tuesday, July 24, 2012

Re: [android-developers] Activity on Service

or display a notification , so  user can start activity by selecting the notification.

On Tue, Jul 24, 2012 at 6:32 PM, Rahul Kaushik <rahulkaushik85@gmail.com> wrote:
Hi,

I have started an activity on Reboot from service, it get started but it bring the activity in front of user
but i dont want show the started activity to the user

MyCode on Service

 public void onCreate() 
   {
    super.onCreate();
    //Toast.makeText(this,"StartAtBootService: onCreate", Toast.LENGTH_SHORT).show();
               Intent i = new Intent(this, AndroidLogin.class);  
               i.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
              this.startActivity(i);
            
            
   
   }


Thanks
RK

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

No comments:

Post a Comment