I am working on Android Mobile, i need to find the current application (which is getting displayed on mobile screen) process name or PID, is there is any way to find out the PID or application name?

I tried to find the active process but I struck up with getting multiple processes but what I need is the one application PID which is currently displaying in mobile screen.

I will be most help full if any one guides me in this problem