last day (44 days later) » 

9:24 AM
heyy
 
Tej
hello
 
Tej
yes
 
List<string> GenderL = new List<string> ();
GenderL.Add ("Male");
GenderL.Add ("Female");

Spinner ddlGender = FindViewById<Spinner> (Resource.Id.ddlGender);
ArrayAdapter ad1 = new ArrayAdapter(this, Android.Resource.Layout.SimpleSpinnerItem, GenderL);
ad1.SetDropDownViewResource(Android.Resource.Layout.SimpleSpinnerDropDownItem);
ddlGender.ItemSelected += new EventHandler<AdapterView.ItemSelectedEventArgs> (ddlGender_ItemSelected);
ddlGender.Adapter = ad1;
after click je opn thy che thats good
but defult selected colore change karva no che
<Spinner
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:id="@+id/ddlGender"
android:fitsSystemWindows="true"
android:clipChildren="true"
android:background="@drawable/th_editText" />
?
 
9:41 AM
u can try with style
other xml class
 
Tej
3
Q: Setting background color for Spinner Item on selection

AjnI am using the Spinner control in my code. I want the item to get highlighted (i.e., background color changed for that item) on selection. How can this be achieved?

create xml as below
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="false" android:drawable="@color/anyColor" />
<item android:drawable="@android:color/transparent" />
</selector>
color what you want
and
set drawable in sppiner by this xml name
 
ArrayAdapter adapter = new ArrayAdapter(mContext,
android.R.layout.simple_spinner_item, arrayQuantity);
 
Tej
6
A: Setting background color for Spinner Item on selection

hanrycreate a xml: for ex:mybg.xml <?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:state_pressed="false" android:drawable="@color/anyColor" /> <item android:drawable="@android:color/transparent" /> </selector> and in your ac...

screen shot gyo aano :(
freelance :p
 
:d
 
:(
WZXXXXX ne vertically center and left algin rakhva shu karva nu?
 
Tej
9:53 AM
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >

<EditText
android:layout_alignParentLeft="true"
android:id="@+id/txt"
android:background="@android:color/darker_gray"
android:layout_height="wrap_content"
android:layout_width="100dp"
android:text="parth"
android:padding="10dp"
android:layout_centerVertical="true"
android:layout_margin="10dp"
aakhu text view vetical center che
layout ni
this is edit text text ,,change it by Textview
 
10:35 AM
ok
 

  last day (44 days later) »