0
我有4個fragments
和每一個我已經實現下面的代碼2 activities
:從谷歌分析沒有得到讀數 - Android電子
import com.google.android.gms.analytics.GoogleAnalytics;
import com.google.android.gms.analytics.Tracker;
//...
private Tracker mTracker;
//...
AnalyticsApplication application = (AnalyticsApplication) getActivity().getApplication();
mTracker = application.getDefaultTracker();
//...
@Override
public void onResume() {
Log.i(TAG, ""+TAG); //TAG represents the name of the current activity/fragment
mTracker.send(new HitBuilders.ScreenViewBuilder().build());
super.onResume();
}
我想要做的是跟蹤每個活動和片段的使用和實時獲得當前活躍用戶並在我的Google Analytics控制檯中收到相關信息,但我沒有設法收到任何數據
PS到目前爲止,我只用我的設備測試