-
How to add different kind of widgets based on array size to existing layout
about 9 years ago
-
about 9 years ago
Hi
You need to create a LinearLayout with orientation set as VERTICAL and then add different widget using addView() method of View Class.
LinearLayout linearLayout=new LinearLayout(this); linearLayout.setOrientation(LinearLayout.VERTICAL); linearLayout.addView(new CheckBox(this)); linearLayout.addView(new TextView(this));
-
1 Answer(s)