Hello,
I am looking at the different documentation for the iOS and Android SDK and I am not sure if it is possible to send different context variable within the same State or Action.
Documentation State for iOS & Android:
It seems incredible that it is not possible, but how would you write that ?
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
// Adobe - track when this state loads
HashMap<String, Object> exampleContextData1 = new HashMap<String, Object>();
exampleContextData1.put("myapp.login.LoginStatus", "logged in");
HashMap<String, Object> exampleContextData2 = new HashMap<String, Object>();
exampleContextData2.put("myapp.login.Template", "templateB");
Analytics.trackState("Home Screen", exampleContextData1,exampleContextData2);
}
Any help, would be appreciated.
Thanks
Solved! Go to Solution.
Topics help categorize Community content and increase your ability to discover relevant content.
Put each context data value in the same HashMap, and then pass one HashMap to the track call:
// Adobe - track when this state loads
HashMap<String, Object> exampleContextData1 = new HashMap<String, Object>();
exampleContextData1.put("myapp.login.LoginStatus", "logged in");
exampleContextData1.put("myapp.login.Template", "templateB");
Analytics.trackState("Home Screen", exampleContextData1);
Put each context data value in the same HashMap, and then pass one HashMap to the track call:
// Adobe - track when this state loads
HashMap<String, Object> exampleContextData1 = new HashMap<String, Object>();
exampleContextData1.put("myapp.login.LoginStatus", "logged in");
exampleContextData1.put("myapp.login.Template", "templateB");
Analytics.trackState("Home Screen", exampleContextData1);
Thanks for your answer.
It exactly what I was looking for.
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies