Skip to Content
Author's profile photo Praveer Kumar Sen

SAP User Tracking System – Part 1


My Question is very simple; can we track user login information? Yes, one way is there, I think everybody knows the answer, but let me explain.

To activate any of the exit, that’s trigger at the time of login.

Yes the same way I did, I Activate the SUSR0001 Exit. And write codes to store login Information of the User.

But here my point comes, from where user is accessing or accessed the System?

Yes, there it is, above a marker in MAP, Now my analysis comes here, I did some analysis and modified the login information while doing the storage process.

Here I have used an already created Web Service, to get the Public IP address of the Used System and location based information.

Below are the Steps which I have followed to store the Information and display the Google MAP with the Login location.

  1. Activate Exist to Store login information.
  2. Activate the Google Service for SAP,  though SAP used IE as default browser,
  3. Activate Google API MAP in Google
  4. Created a Customized Service to Call the Google Map
  5. Program to Display users Logged Information.
  6. Program, to see current login Information of User based on today date.

  1. Activate Exist to Store login information.

          As I have explained, we have to store the User Login Information, since SAP is not storing the 

          All Login information, you can check the current login information in USR41 Table,

          Once you log-off and re-login, the current login information will update into the same table.

          So I have to store the all Login Information in custom table, Below is the Table Information

2.Activate the Google Service for SAP,  though SAP used IE as default browser,

     I have used CL_GUI_HTML_VIEWER class to display the Google map in SAP screen.

     When I have tried 1st time, the map itself not displaying and I did some analysis and found. SAP      opens IE (Internet Explorer) as default browser.

     I have put a thread in this forum and found the Answer. it’s contains the all changes information to activate      the Google service in SAP.

     Note: All Changes has to do in Application Server Side.


3. Activate Google API MAP in Google

     To use Google MAP in coding, we require Google Service Key, Please find the below link to activate the Google API Key.

     Follow the all steps from the above link, and generate the API key.

     I have stored the API Key Information in customize Table and fetch the same through Class Method.

     Below is the table, where I am storing the Information.



     In this table, I am storing the MAP API key, Map Type and Map Refresh Time.


     Based on the user id, I am storing the information.

     Below are the Methods I am using to SET and GET the information from the ZGEOKEY table.


     a. SET_GEO_KEY



     b. GET_GEO_KEY



     Please find the SET_GEO_KEY and GET_GEO_KEY method code in attachment.

SAP User Tracking System – Part 2

Happy Learning.. 🙂


Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Sreehari V Pillai
      Sreehari V Pillai

      Good one Praveer.

      Author's profile photo Prashanth P
      Prashanth P

      Very informative, good one!

      Author's profile photo Matthew Billingham
      Matthew Billingham

      It's called an EXIT not an EXIST: Please edit your content accordingly. You should also pay attention to the layout - with line wraps, it is not very easy to read.

      Author's profile photo Praveer Sen
      Praveer Sen
      Blog Post Author

      ya sure, i will do that.

      Thanks for the guidance.