Android Google Tag Manager

喜欢而已 提交于 2019-12-02 04:27:01

If you are following those steps carefully then this warning doesn't stop you from opening container or sending data to analytics. I am also following instructions available here. I'm getting these logs
  W/GoogleTagManager(3101): Failed to extract the container from the resource file. Resource is a UTF-8 encoded string but doesn't contain a JSON container
  V/GoogleTagManager(3101): The container was successfully loaded from the resource (using binary file)

Follow this link to create Macros and Tags. http://online-behavior.com/analytics/mobile-apps-tag-manager

Look carefully if you have created firing rules for you tags. Also verify if you have published your Container. Try opening your container in onCreate() method.

In GTM V4 after opening container in onCreate(), preferred way is that you need to push your event like this in your onStart() method.

 DataLayer mDataLayer = TagManager.getInstance(this).getDataLayer();
 mDataLayer.pushEvent("your event name here", DataLayer.mapOf("screenName",SCREEN_NAME));

Update: I have attached image to show how I'm changing Basic Configuration. Hope this helps.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!