how to put dynamic button in android useing its position -
how put dynamic button using xml. want fetch position of button xml , place them in screen.
what mean dynamic?
create xml file called filename.xml, put in. change drawables necessary. bt_return , bt_returnpress
<?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:drawable="@drawable/bt_return" android:state_pressed="false" /> <item android:drawable="@drawable/bt_returnpress" android:state_pressed="true" /> <item android:drawable="@drawable/bt_return" android:state_focused="false" /> <item android:drawable="@drawable/bt_returnpress" android:state_focused="true" /> </selector>
then assign filename.xml background of dynamic button u want.
Comments
Post a Comment