InputTransparent vs IsEnabled in Xamarin Forms

One of the problems in Xamarin Forms is that it is not possible to setup the text colors of disabled elements (elements where IsEnabled property is set to false).
However you do not need to set the IsEnabled property to disable it, there is an alternative property called InputTransparent.
Setting InputTransparent to true (by default it is false) will effectively disable the control by not allowing the user to interact with it.

The only drawback is that there is no visual indicator that the control is disabled, however this can be achieved by manually changing the text or background color of the control when it is disabled in this way.

Leave a Reply

Your email address will not be published. Required fields are marked *