I can't create an onCheckedChanged listener for my RadioGroup

前端 未结 3 1931
天命终不由人
天命终不由人 2021-01-26 05:29

I\'m trying to create an onCheckedChanged Listener for my RadioGroup, but eclipse is throwing erros at me. this is the code

<         


        
3条回答
  •  长情又很酷
    2021-01-26 06:05

    I think you have imported the wrong package.

    You should import android.widget.RadioGroup.OnCheckedChangeListener

    instead of android.widget.CompoundButton.OnCheckedChangeListener

提交回复
热议问题