AndyJarrett

Dynamically hiding a HTML CFGridColumn

I've been working with CFGrids recently especially the HTML format. One recent issue I had was the ability to dynamically hide a column once the grid has been loaded. Luckily the Ext's framework that sits underneath is full of hidden gems in ways you can add extra functionality and ColdFusion provides ColdFusion.Grid.getGridObject that allows you to tap into this First, lets create our grid args = structNew(); args.autowidth = true; args.name = "myTestGrid"; args.format = "html"; args.width = "250"; args.query = "gridData"; The idea of the code will be to dynamically hide the first column onLoad. Complete code should look like this: args = structNew(); args.autowidth = true; args.name = "myTestGrid"; args.format = "html"; args.width = "250"; args.query = "gridData";