Lakhae
Lakhae

Reputation: 1899

How to disable Telerik datetime picker in ASP.Net MVC 4?

I am trying to make datetime picker readonly. I found the following code in the internet

  $("#RequestedDate").attr('disabled', true)
    .next("span.t-select")
    .children("span.t-icon-calendar").css("visibility", "hidden");

which works great but it reset datetime to minimun datetime.

Upvotes: 0

Views: 472

Answers (1)

asymptoticFault
asymptoticFault

Reputation: 4529

You want to set the "readonly" attribute, not "disabled". If it's disabled the value won't be picked up.

Upvotes: 1

Related Questions