I have got a linearlayout form. This form has got a 2 fields. I would like get this effect:
Two fields, one is hidden (under top bar). When i click button 'ok' this linear layout go down and display next field (hidden field). How get this effect?
RelativeLayout
.android:visibility="gone"
for the first of them.android:layout_below="@id/yourFirstField"
for the second.onClickListener
to the button and, in the body on the listener in your Java class, change the visibility of the first field to visible (I guess it's an EditText, so EditText.VISIBLE
)android:animateLayoutChanges="true"
to your RelativeLayout (the container of both items).This should work!! I hope this helps!!