w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
How to add text field with button when click on Add(+) button, again click new added button add one more fields in android?

You have add like the following code,

Button myButton = new Button(this);
LinearLayout ll = (LinearLayout)findViewById(R.id.myLayout);
LayoutParams lp = new LayoutParams(LayoutParams.MATCH_PARENT,
ll.addView(myButton, lp);

© Copyright 2018 w3hello.com Publishing Limited. All rights reserved.