android

钓鱼的熊猫 2012-06-19 05:19:51
android页面怎么把数据显示在类似表格的控件上
...全文
81 6 打赏 收藏 转发到动态 举报
写回复
用AI写文章
6 条回复
切换为时间正序
请发表友善的回复…
发表回复
gongxujun 2012-06-27
  • 打赏
  • 举报
回复
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginRight="10dip"
android:layout_marginTop="10dip"
android:focusable="true"
android:focusableInTouchMode="true"
android:orientation="horizontal">

<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/str_url" />


<AutoCompleteTextView
android:id="@+id/et_mmssend_url"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="5dip"
android:layout_weight="0.27"
android:completionThreshold="1"
android:dropDownHeight="wrap_content" />

</LinearLayout>



et_url = (EditText)findViewById(R.id.et_mmssend_url);
用类似的方法
嗨皮 2012-06-27
  • 打赏
  • 举报
回复
网上这个例子一大堆,稍微找找就多的不得了,这些只要百度谷歌一下就行了
mimitracely 2012-06-26
  • 打赏
  • 举报
回复
String [] s={"字符串1",
"字符串2",
"字符串3",
"字符串4",
"字符串5"};
ArrayAdapter aa=new ArrayAdapter<String>(this,android.R.layout.simple_list_item_1,s);
listView.setAdapter(aa);

这是显示到 listView中的代码,
Aria_zuo 2012-06-22
  • 打赏
  • 举报
回复
xml文件中设置

<ListView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:entries="@array/books"
/>

android:entries="@array/books"
books就是你存在的数据数组
feifeifei313 2012-06-21
  • 打赏
  • 举报
回复
好像是用gridview,tablelayout之类的吧,有高手知道的贴出详细例子分享一下吧
鄙人姓胡 2012-06-21
  • 打赏
  • 举报
回复
用ListView可以实现,参考下面这个:

http://www.open-open.com/lib/view/open1333372619624.html

80,351

社区成员

发帖
与我相关
我的任务
社区描述
移动平台 Android
androidandroid-studioandroidx 技术论坛(原bbs)
社区管理员
  • Android
  • yechaoa
  • 失落夏天
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧