J Jamie Member Licensed User Longtime User Feb 28, 2011 #1 I'm trying to create a program to put a fullscreen static image on the screen when the proximity sensor is activated. When taking a call on bluetooth the screen comes on in my pocket and bad stuff then happens I have everything working with the sensor and the image but when the main activity is paused I of course can't callsub the activity to put the image on screen. Has anyone figured out how to call the api that controls screen off in android? Or is it possible to load a new program that could then display the image, maybe by using intent, shell???? Or am I just missing something and it is possible to bring the main activity back to the foreground as happens when I press the notification. Any ideas would be most helpful Thanks Jamie...
I'm trying to create a program to put a fullscreen static image on the screen when the proximity sensor is activated. When taking a call on bluetooth the screen comes on in my pocket and bad stuff then happens I have everything working with the sensor and the image but when the main activity is paused I of course can't callsub the activity to put the image on screen. Has anyone figured out how to call the api that controls screen off in android? Or is it possible to load a new program that could then display the image, maybe by using intent, shell???? Or am I just missing something and it is possible to bring the main activity back to the foreground as happens when I press the notification. Any ideas would be most helpful Thanks Jamie...
Erel B4X founder Staff member Licensed User Longtime User Mar 1, 2011 #2 You can start your activity from the service by calling StartActivity(Main). Upvote 0
J Jamie Member Licensed User Longtime User Mar 1, 2011 #3 Wow that simple! Thanks so much Erel Upvote 0