如何添加意见线性布局? [英] how to add views to linear layout?

查看:118
本文介绍了如何添加意见线性布局?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有可能陆续添加视图线性布局之一,向上的方向。

It is possible to add views to Linear Layout one after another in upward direction.

如果任何一个工作的,请帮我

if any one working on that,please help me

推荐答案

您可以以编程方式添加:

You can add it programmatically with:

LinearLayout layout = findViewById(R.id.layout);
layout .addView(newView, index);

您只需要与指数随时添加= 0

You just have to add always with index = 0

这是回答你的问题?

这篇关于如何添加意见线性布局?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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