G GaNdAlF89 Active Member Licensed User Longtime User Sep 6, 2012 #1 I want to restart my app pressing a button. How can I do this? Can you post an example code?
mc73 Well-Known Member Licensed User Longtime User Sep 6, 2012 #2 One way I can think of, is to start a service module before your activity.finish command. Then, use a timer in your service module, in which you can start again your app. Upvote 0
One way I can think of, is to start a service module before your activity.finish command. Then, use a timer in your service module, in which you can start again your app.
klaus Expert Licensed User Longtime User Sep 6, 2012 #3 I want to restart my app pressing a button. Click to expand... Why do you want to restart you own application ? Best regards. Upvote 0
I want to restart my app pressing a button. Click to expand... Why do you want to restart you own application ? Best regards.
G GaNdAlF89 Active Member Licensed User Longtime User Sep 6, 2012 #4 mc73 said: Then, use a timer in your service module, in which you can start again your app. Click to expand... Thanks...How can I start my app from service code? klaus said: Why do you want to restart you own application ? Click to expand... If I have strange behavior of app... Last edited: Sep 6, 2012 Upvote 0
mc73 said: Then, use a timer in your service module, in which you can start again your app. Click to expand... Thanks...How can I start my app from service code? klaus said: Why do you want to restart you own application ? Click to expand... If I have strange behavior of app...
thedesolatesoul Expert Licensed User Longtime User Sep 6, 2012 #5 Using a service module with a timer/Activity.Finish will not restart the app. It will only restart the activity. Can you tell us more about the behaviour of your app? Maybe it is possible to trigger on some phone intents? Or you can set up your service to start later with StartServiceAt(later) and then use ExitApplication. Upvote 0
Using a service module with a timer/Activity.Finish will not restart the app. It will only restart the activity. Can you tell us more about the behaviour of your app? Maybe it is possible to trigger on some phone intents? Or you can set up your service to start later with StartServiceAt(later) and then use ExitApplication.
Johan Schoeman Expert Licensed User Longtime User Nov 24, 2013 #6 Please help. I have used a combination of Simple_Alarm and WheelView to create an alarm clock. It works perfectly but once I have scheduled the alarm and "closed" the app I want the app to come "alive" when alarm starts sounding so that I can shut the alarm or select for eg "snooze" that will silent the alam for 5 or 10 or 15 minutes (user selecteable) i.e I want to be able to interface/interact with the app. How do I make the app come "alive" again so that I can interface/interact with it? Upvote 0
Please help. I have used a combination of Simple_Alarm and WheelView to create an alarm clock. It works perfectly but once I have scheduled the alarm and "closed" the app I want the app to come "alive" when alarm starts sounding so that I can shut the alarm or select for eg "snooze" that will silent the alam for 5 or 10 or 15 minutes (user selecteable) i.e I want to be able to interface/interact with the app. How do I make the app come "alive" again so that I can interface/interact with it?
thedesolatesoul Expert Licensed User Longtime User Nov 24, 2013 #7 Possibly trigger on a broadcast from the alarm clock (or use StartServiceAt). I am not sure what that broadcast is though. Maybe look at the android developers docs. Upvote 0
Possibly trigger on a broadcast from the alarm clock (or use StartServiceAt). I am not sure what that broadcast is though. Maybe look at the android developers docs.
Johan Schoeman Expert Licensed User Longtime User Nov 24, 2013 #8 any tips if I use StartServiceAt? What is the service that should be called to revive the app - App name, Package name, or......? Upvote 0
any tips if I use StartServiceAt? What is the service that should be called to revive the app - App name, Package name, or......?
Erel B4X founder Staff member Licensed User Longtime User Nov 24, 2013 #9 There are several examples with StartServiceAt: http://www.b4x.com/android/forum/pages/results/?query=startserviceat&page=1 Upvote 0
There are several examples with StartServiceAt: http://www.b4x.com/android/forum/pages/results/?query=startserviceat&page=1
Johan Schoeman Expert Licensed User Longtime User Nov 24, 2013 #10 I am starting the alarm service by making use of StartServiceAt. I need to "kick start" the app to come "alive" so that I can interface/interact with it once the alarm triggered. I am a bit lost in the "kick start" process that should be followed. Upvote 0
I am starting the alarm service by making use of StartServiceAt. I need to "kick start" the app to come "alive" so that I can interface/interact with it once the alarm triggered. I am a bit lost in the "kick start" process that should be followed.
Erel B4X founder Staff member Licensed User Longtime User Nov 24, 2013 #11 You should create a service and call StartActivity from the service to show an activity. Upvote 0