This is a migrated thread and some comments may be shown as answers.

Prevent change in AutoComplete field based on other page data

1 Answer 14 Views
AutoComplete
This is a migrated thread and some comments may be shown as answers.
Richard
Top achievements
Rank 1
Richard asked on 05 Mar 2014, 09:19 PM
I have an AutoComplete that is context dependent on other fields of the View screen.  For example, if a work order number is null, the autocomplete should function normally, however, if the workorder is present, then the autocomplete should not accept any changes because the value is then dictated by the work order and would only change if the work order changed.  I don't want to make the field read-only because then it won't post it's data to the server.  That would make things complicated and I adore simple.

I don't find an onBeforeChange event for the widget... is it possible to hook one up, and if so how?  If not, please suggest a solution.

Thanks!

1 Answer, 1 is accepted

Sort by
0
Accepted
Georgi Krustev
Telerik team
answered on 06 Mar 2014, 09:12 AM
Hello Richard,

An input element with readonly attribute will be posted to the server (it will be successful). Based on this I would suggest you make the widget readonly when you do not want to allow any modifications. Use the readonly method for that task

Regards,
Georgi Krustev
Telerik

DevCraft Q1'14 is here! Join the free online conference to see how this release solves your top-5 .NET challenges. Reserve your seat now!

Tags
AutoComplete
Asked by
Richard
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Share this question
or