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
750
Checkbox_checkedChanged event
posted

Hi all I have one checkbox and one grid in my page. I want to hide one column of the grid  when  check box is checked. I have binded data at pageload. This checkbox is just to make columns visible or invisible. Whenever i check this checkbox its firing an event which loads my  page again. Is there any way  to hide that column without doing whole page load.

Any suggestions will be highly appreciated.

Parents
  • 28464
    Verified Answer
    posted

    Hello,

    Yes, I think this is possible by using the client side object model (CSOM) of the grid. You can check out the Column CSOM documented here:

    http://help.infragistics.com/Help/NetAdvantage/NET/2008.3/CLR2.0/html/WebGrid_Column_Object_CSOM.html

    and use the setHidden function in particular to hide a column of the grid on the client-side without postback.. This can be executed on a client-side event of the checkbox, e.g.

    <input type=checkbox onclick="hideColumn()" ... />

    Hope this helps.

Reply Children