android - Spinner - how to set border around drop down list? -


i have spinner , want know how can put border around

    spinner dropdown = (spinner)findviewbyid(r.id.spinnerupdatecontactmethod);     string[] items = new string[]{"1", "2", "three"};     arrayadapter<string> adapter = new arrayadapter<string>(this, android.r.layout.simple_spinner_item, items);     dropdown.setprompt("please select ");     dropdown.setadapter(adapter); 

the prompt doesn't come on screen. please me this.

for custom border can create xml file inside drawable folder

<shape xmlns:android="http://schemas.android.com/apk/res/android"     android:shape="rectangle">     <solid android:color="@color/white_overlay_8x" />     <corners android:radius="6dip" />     <stroke         android:color="@color/white"         android:width="@dimen/dot" />  </shape> 

and set

android:background=@drawable/file; 

in spinner(xml file of activity)


Comments

Popular posts from this blog

Payment information shows nothing in one page checkout page magento -

tcpdump - How to check if server received packet (acknowledged) -