I want to display a Toast message when clicked on disable button.
button.setEnable(false);
button.setOnClickListener(new View.OnClickListener()
{
@Override
public void onClick (View v)
{
Toast.makeText(SliderDemo.this, "Button Disabled",Toast.LENGTH_LONG).show(); }}
Can we use both Touch listener and Click listener on same button?
You cant click a disabled button.Try doing this ,
Add this lines in your color.xml