android - How to create relativelayouts with java code? -


i need learn creating relativelayouts java code instead of xml code.

for example, nice understand how build xml java code:

<relativelayout xmlns:android="http://schemas.android.com/apk/res/android"     android:layout_width="fill_parent"     android:layout_height="fill_parent" >  <button         android:id="@+id/btnbutton1"         android:layout_width="wrap_content"         android:layout_height="wrap_content"         android:text="button 1"/> <button         android:id="@+id/btnbutton2"         android:layout_width="wrap_content"         android:layout_height="wrap_content"         android:text="button 2"         android:layout_torightof="@+id/btnbutton1"/>       <button         android:id="@+id/btnbutton3"         android:layout_width="wrap_content"         android:layout_height="wrap_content"         android:text="button 3"         android:layout_below="@+id/btnbutton1"/> </relativelayout> 

i can't find examples of doing java code

please, can me transform layout java code? or can give me tutorial links relativelayouts java code?

thanks

there plenty of examples out there! try tutorial, covers elements need... , best, gives programmatically examples kind of layouts, solve future questions, ;)

http://mobile.tutsplus.com/tutorials/android/android-user-interface-design-relative-layouts/


Comments

Popular posts from this blog

jasper reports - Fixed header in Excel using JasperReports -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -

delphi - How to convert bitmaps to video? -