android - Autorun application when phone connected to pc -


is there way open application dekstop pc (such autorun) when android device connected pc?

say have been creating android application, , application installed in android device (phone / tablet). , want give application special authority let device run app automatically when device connected pc.

actually, command run app command open web browser.

my question is:

how give application special authority let device run app automatically when device connected pc?

can give me lighten?

many in advance!

you can register broadcast receiver wait example battery change state broadcast (see this: http://developer.android.com/training/monitoring-device-state/battery-monitoring.html). when such broadcast received, determine if connected pc , start proper activity.

i guess might need application work time (have started sticky service) make work.


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -