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
220
Client side add columns to grid
posted

Is it possible to add a column to a grid on the client-side? 

I need to be able to create new columns and add them to a grid, I've already achieved this in the code behind but I want to move it to the client side because I'm getting the column names I want to use from a javascript call to the window opener.

Thanks,

Colette 

Parents
  • 19308
    Verified Answer
    posted

    Hi Colett,

    You can't add a column on the client-side, but you can hide and show columns, as well as change the column header.  I'm not sure what your scenario is but you may be able to simply store an extra hidden column on the client-side to be used when you need it. 

    Also, if you're using a window opener, you can pass the additional information in the querystring and parse that on the server-side.  For instance

    open("default2.aspx?action=addcolumn&column=price");

    Hope this helps,

    -Tony

Reply Children