显示在Tabhost导致机器人/月食 [英] Showing result on Tabhost in android/eclipse

查看:113
本文介绍了显示在Tabhost导致机器人/月食的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

以上仿真图像是刚刚从用户输入并显示在同一个page.But我需要表现出的Tabhost(它希望成为下页)这个问题的答案的EditText上回答类似下面的图像。

The above emulator image is just getting the input from the user and showing the answer in the edittext of the same page.But i need to show that answer on the Tabhost ( which wants to be on the next page ) like the below image..

如何实现这个概念..?

How to achieve this concept..?

推荐答案

U可以调用同一个选项卡当u调用活动 只要把身份证给你的当前标签,并调用标签当u调用一个活动 --put它TabActivity

U can call the same tab when u calling the activity just put id to your current tab and call the tab when u call a activity --put it in TabActivity

public void switchTab(int tab) {
tabHost.setCurrentTab(tab);
}

在活动通话TabActivity

in the activity call TabActivity

TabsActivity ParentActivity;
ParentActivity = (TabsActivity) activity.getParent();
ParentActivity.switchTab(0);// 0 is a current tab id and u can used what ever tab id u want to shift  

我一跳,这可能有助于U

i hop this may help u

这篇关于显示在Tabhost导致机器人/月食的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆