How to run an application before any other application in android?
<p>I want to write a program in that if somebody wants to open a application (like Contacts Application) , first my program starts and user enter a password and if password is correct , let contacts program to open.</p>

<p>i know it s possible because <a href="https://market.android.com/details?id=com.cc.applock&amp;feature=search_result" rel="nofollow">App Lock</a> program does it.</p>

<p>should i run a service?</p>
