Reputation: 401
Hi so i made 3 spinners whit values but after i run the app and select one value, the spinner value changes but i can't see it. Picture 1 Picture 2
I selected the value 20 but in picture 2 i can't see the value Here is my xml file code:
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<Spinner
android:id="@+id/Spinner1"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text=":" />
<Spinner
android:id="@+id/Spinner2"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<Spinner
android:id="@+id/Spinner3"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</LinearLayout>
Here is my java class code:
spinerOra = (Spinner) findViewById(R.id.Spinner1);
ArrayAdapter<CharSequence> AdaptorOra = ArrayAdapter.createFromResource(getApplicationContext(),
R.array.ora , android.R.layout.simple_spinner_item);
AdaptorOra.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
spinerOra.setAdapter(AdaptorOra);
spinerMinute1 = findViewById(R.id.Spinner2);
ArrayAdapter<CharSequence> AdaptorMinute1 = ArrayAdapter.createFromResource(getApplicationContext(),
R.array.minute1, android.R.layout.simple_spinner_item);
AdaptorMinute1.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
spinerMinute1.setAdapter(AdaptorMinute1);
spinerMinute2 = findViewById(R.id.Spinner3);
ArrayAdapter<CharSequence> AdaptorMinute2 = ArrayAdapter.createFromResource(getApplicationContext(),
R.array.minute2, android.R.layout.simple_spinner_item);
AdaptorMinute2.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
spinerMinute2.setAdapter(AdaptorMinute2);
What can i do so that the spinner will show me the selected value?
Upvotes: 0
Views: 955
Reputation: 401
So sometimes the answer can be something really stupid so I didn't notice that the text is white and the background is also white pff.... it took me 30 minutes to find the answer haha
Upvotes: 3