I have several tab, has the same layout in a TextView, now I want to get in the View Tab currently in this TextView.
I
TextView tv = (TextView) mTabHost.getCurrentView () findViewById (R.id.tvLeftUpValue);.
Obtained TextView empty.
Or can get the current instance of the corresponding Class View also line ah.
For example
FragmentPage_idle idle = (FragmentPage_idle) mTabHost.getCurrentView () getClass ();.
New, first time Android, sorry, forgive me
<-! Main posts under Banner (D4) -><-! Posts under the main text (D5) ->
Reply:
There are a number of layout controls tag ID is not the same issues now.
Reply:
Directly to the original fine. This is not to understand the principles of fate
switch (mTabHost.getCurrentTab ()) {
case 0: {/ /
TextView tv = (TextView) findViewById (R.id.tvLeftUpValue);
tv.setText (ds.getDataItemS ("x00020001"));
}
}
No comments:
Post a Comment