I would like to access the public method of an Activity run by a TabActivity using:
TabHost tabHost = getTabHost();
Intent intentMsgsView = new Intent().setClass(this, TeamHuddleScreenMsgsView.class);
tabHost.addTab(tabHost.newTabSpec("msgs").setIndicator("Messages").setContent(intentMsgsView));
Basically, what I what is to let the parent Activity call a method in child Activity in order to do something. Is this possible?
I did try this:
((TeamHuddleScreenMsgsView)getTabHost().getCurrentTabView().getContext()).refreshModel();
but I'm encountering a ClassCastException. It seems that the getContext() still gives the TabActivity. Any help on how to get the child Activity?
Thanks.