android - Add a new editText on Button press -
i have simple table layout empty row
<tablerow android:id="@+id/range_input1" > </tablerow>
i add edittext row when user presses button. quite unsure on how though. proper way of doing it? far can think of 2 ways, first 1 have edittext in row , make row hidden, or try create edittext when button pressed.
the problem have no idea how either option, nor find tutorials on explaining how add or hide forms.
also wondering if possible slide effect.
thanks help!
add edittext
tablerow
, make row visibility gone :
<tablerow android:id="@+id/range_input1" android:visibility="gone"> <edittext /> </tablerow>
and in button
on click listener:
tablerow row = (tablerow) findviewbyid(r.id.range_input1); row.setvisibility(view.visible);
Comments
Post a Comment