Home  >  Forum  >  Android
Post New Query

Android - How to make TextView clickable programmatically



Asked on September 15, 2015
In my android application, I need to make TextView clickable on and off programmatically. How to achieve it.





Replied on September 15, 2015
Do as follows.

TextView text = (TextView) activity.findViewById(R.id.text);
text.setClickable(true)


or
text.setClickable(false)




Replied on September 15, 2015
Thanks.

Write Answer




©2019 concretepage.com | Privacy Policy | Contact Us