Questions tagged [android-radiobutton]

Use for the android.widget.RadioButton element. Radio buttons are normally used together in a RadioGroup.

Radio buttons allow the user to select one option from a set. You should use radio buttons for optional sets that are mutually exclusive if you think that the user needs to see all available options side-by-side.

Radio buttons are normally used together in a RadioGroup. When several radio buttons live inside a radio group, checking one radio button unchecks all the others.

Useful links

347 questions
0
votes
2 answers

Merge the radio button and imageviews programmatically

I want to show the images with radio buttons and show this with radio group as user would be able to choose the option by reading the text and viewing the image. How can I make this possible? Here is the code by which radio buttons are created and…
0
votes
2 answers

dynamic radio group to checkchangelistener is not working and also not showing/viewing

I created the radio buttons dynamically and set them in the radio group and it is working good but when i click the radio buttons to get the value but onclick is not working here is the code: in this when i click on checked change listner there is…
Awais
  • 1,157
  • 9
  • 15
0
votes
0 answers

Android RadioGroup arranged in a circle

I'm trying to find a way to organize a single group of radio buttons into a circle shape. All I can think of is a complex setup of RelativeLayouts, but it gets messy when switching devices. Please help!
BoltzmannBrain
  • 5,082
  • 11
  • 46
  • 79
0
votes
3 answers

Sending values from 2 Radiogroups using Bundle passes only the second RadioGroup selected value

Hi I am stuck in a very strange code bug. Please Help!!!! My project has 2 Activities. 1) The First Activity is a form which includes 2 RadioButtonGroups having 2 Radio Buttons each called 'Yes' and 'No'. Default is 'No' 2) It has a Submit button.…
0
votes
1 answer

android - making ListView with radio buttons work

I have made a listview with radiobuttons, but the items don't behave like normal radiobuttons because there is no radiougroup that bonds them together I think. Can I add them to a radiogroup that is not in the xml programatically? I want to be able…
0
votes
1 answer

Android RadioGroup get the RadioButton index

I created a RadioGroup programmatically and added in it some RadioButton (they can be 1 or 2 or 3, it dependes from the database). I tried this code but it crashes when I try to get the RadioButton selected ID final RadioGroup radioGroup =…
1megg1
  • 33
  • 1
  • 7
0
votes
2 answers

Radiogroup setOnCheckedChanged ids issues

I was trying to check if a radiobutton was either checked or not and do some stuff in consequence when I found this weird behaviour which I can't understand. I must say the radiogroup is inside a PreferenceDialog which is my only explanation for the…
user1903
  • 790
  • 1
  • 6
  • 10
0
votes
0 answers

Radio Button to center of it's background image in Android

I need to center my radio button in a the background image ,by defaults it is aligned to left of the screen.any one have idea? here is my current code with 3 radio butoons inside radio button group first has image background
droidNDK
  • 85
  • 1
  • 9
0
votes
1 answer

Why is my RadioGroup so large yet devoid of contents/RadioButtons?

Here is the portion of XML that I have in my Android Layout file that should generate a RadioGroup with three RadioButtons inside:
0
votes
0 answers

is it possible to inflate a layout and set as a view for RadioButton - android

I have three RadioButton's inside a RadioGroup I removed the check inside the RadioButton by using android:button="@null" Now I want to inflate a layout like this screen shot, inside the RadioButton with "Text A", "Small Title" is that possible? I…
yashhy
  • 2,856
  • 5
  • 31
  • 57
0
votes
1 answer

RadioButton with more than text

I'm trying to create a RadioGroup with RadioButtons that have more than text only. The image below will make things easier to understand. I want the RadioButton to be selected when the user clicks somewhere in the layout around it. I've tried do do…
dumazy
  • 13,857
  • 12
  • 66
  • 113
0
votes
2 answers

How can I get my Android radio buttons to use less padding?

I want my radio buttons to get a little cozier with each other. I hoped to put them in a radiogroup, thinking that would automatically provide the "if this one is checked, the other ones automatically uncheck" logic. But with a…
0
votes
1 answer

select a radio button and when i go back to this activity the selection still exists?

customlist and contain radiobuttons and I want to select one radiobutton and it works. But i want to save that raidobutton which i select. I used sharedpreference but i couldnt do it . i know the sharedpreference is the good way to save value in…
0
votes
1 answer

RadioButton vs Spinner

This is more of an opinion based question. I'm working on an app that will give the user a choice of 2 items of which the user must choose one. Now to implement this, we have :- RadioButtons in a RadioGroup Spinner For such a basic thing, I think…
d3m0li5h3r
  • 1,957
  • 17
  • 33
0
votes
1 answer

I want to pass intent values based on the radiobutton checked and only after button clicked by the user here is my code

How to pass intent values based on the radio button checked, and intent should be started only after clicking the button,and the values should be passed based on the swith case statement here is my code please help me out.. package…