Quantcast
Channel: android developer Feed
Viewing all articles
Browse latest Browse all 35

How do you configure Google Analytics v2 lib in Android?

$
0
0

Answer

Create an xml file in the res/values directory called as analytics.xml

<?xml version="1.0" encoding="utf-8" ?>

<resources xmlns:tools="http://schemas.android.com/tools" tools:ignore="TypographyDashes">
  <!--Replace placeholder ID with your tracking ID-->
  <string name="ga_trackingId">UA-41303275-1</string>

  <!--Enable automatic activity tracking-->
  <bool name="ga_autoActivityTracking">true</bool>

  <!--Enable automatic exception tracking-->
  <bool name="ga_reportUncaughtExceptions">true</bool>
 
  <bool name="ga_debug">false</bool>
</resources>


Viewing all articles
Browse latest Browse all 35

Trending Articles