Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
2915
Reset the selected item in XamComboEditor
posted

Hi,

     I have some data that is populated and displayed in the XamComboEditor, which in turn in embedded in a XamDatagrid column. By default I need to have the IsEditable to true for the combo editors.However, for some cases, I need to prevent this. I tried the TextChanged event but was not able to reset it to the previous selectedItem, is there any other event to handle this?

 

Parents
  • 30945
    Verified Answer
    Offline posted

    Hello Arpita,

     

    Thank you for your post. I have been reading through it and in order to not allow editing of some of the cells in a Field, I can suggest using the EditModeStarting event of the XamDataGrid. In the event handler, you can check the column and the value of the cell and cancel the event using the e.Canceled property. By doing so the cell containing a certain value will not be allowed to go in edit mode. You can also use the same event of the XamComboEditor, and in the event handler you can check only the value of the editor. I have created a sample application for you that demonstrates the approach.

     

    Please let me know if you need any further assistance on the matter.

     

    Sincerely,

    Krasimir

    Developer Support Engineer

    Infragistics

    www.infragistics.com/support

    PreventEditingOnCellBaseOnValue.zip
Reply Children