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
730
Server side Checkbox column
posted

Hello,

I have a webdatagrid that I need a checkbox column setup with it. I have tried using the template field but ran into issues firing the event when the checkbox is changed and when sorting the grid. I have tried changing the template field to a bound field but still i wasn't able to do it. I checked the samples online, none of them had one either.

How can I implement this?

  • 8421
    posted

    Hello,

    Does David's approach work for you?  Please let me know if we can provide any further assistance with this matter.

  • 33839
    Suggested Answer
    posted

    Hi marcgh,

    In 11.1, we will have both a bound and unbound checkbox column available.  So you have to look forward to in around a month.  In the meantime, you'll need a work around.  What I would do often times is to have a visible template field showing the checkbox and a bound data field that is hidden and connected to the actual data field.  When the checkbox is changed on the client, call set_value on the cell that is bound to the real value and change it.  You'll need the editing core on.  Handle the initialize row event to set the correct state of the checkbox in the templated field.  This should work.  Let us know if you have trouble.

    regards,
    David Young