How can I hide a WebGrid column at run time ?
For example, I want to hide the Parametro
column, it would look like this:
grid.Column("Empresa", "Empresa"),
if(item.valor1 == X){
grid.Column("Parametro", "Parametro"),
}
grid.Column("Data", format: @<text>@item.DataInclusao.ToString("dd/MM/yyyy")</text>),
In this post: Hiding a column from a WebGrid shows how hide but not at runtime.