1 2 3 4 5 6 7 |
private void addToChild(String label, String value) { LinearLayout item = findViewById(R.id.dataWrapper);//ViewGroup where we need to append views View child = getLayoutInflater().inflate(R.layout.model_dialog_row, null); //Layout which we need to add ((TextView) child.findViewById(R.id.modelDialogRowLabel)).setText(label); ((TextView) child.findViewById(R.id.modelDialogRowValue)).setText(value); item.addView(child); } |