可以的,先声明一个变量,再create,然后设置其parent和postion,最后show出来就行了。要注意的是:1、控件必须要有parent2、控件最好指定位置和大小信息3、控件要显示出来,必须要调用show方法。