Home » Android » How can i get the utm variables on the launch of main activity in android while referred from any marketing site?

How can i get the utm variables on the launch of main activity in android while referred from any marketing site?

Posted by: admin May 14, 2020 Leave a comment

Questions:

How can I get the UTM variables on the launch of main activity in android while referred from any marketing site?

How to&Answers:

I don’t get the main idea, but your activity has intent, that started the activity. So if it was started from url you can call getIntent().getData()to get the Uri.
After that you can find out all the params in that uri because Uri class has a lot of helper methods, for example getQuery.