Page 1 of 1

Dynamic Column Selection

Posted: Fri Feb 26, 2016 8:56 am
by ppbedz
Is there any way to dynamically set the grid columns? It does not appear that you can bind a field to number of columns or column size. I wanted to resize my grid columns based on user input.

Example: I want the user to see standard comments for vendor and/or item number. If the vendor number is specified as input, they really don't need to see a column with the vendor number (same for item). I only want to show those columns if they have requested "all" vendors or "all" items. Even "group suppression" would be nice.

Thank you, Patti

Re: Dynamic Column Selection

Posted: Fri Feb 26, 2016 12:12 pm
by ppbedz
I just discovered the removecolumn method. It works, however I would like to conditionally remove several columns. Is there a way, for example to remove columns 2-4 ? Also, how would I put them back? I was thinking I would code the "onload" to show whatever columns pertain to the user's selections..... ?

Re: Dynamic Column Selection

Posted: Fri Feb 26, 2016 2:08 pm
by SeanTyree
Patti,
You might try resizing the columns that you don't want to display to 0px width. This effectively hides the columns but would allow you to redisplay them by re-setting the width.

Sean

Re: Dynamic Column Selection

Posted: Fri Feb 26, 2016 4:14 pm
by ppbedz
Thank you, Sean. I have everything working now. Have a nice weekend! - Patti