Click here to Skip to main content
15,889,834 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
HI..
I am new to MVC & Jquery..

In my requirement i had a button by click on that button it should shows all columns of the web grid in a listbox, be selecting those columns to show and click show button then it vl those columns only in the webgrid.

How it is possible in MVC with Jquery..



Thanks ,
Honey.
Posted

1 solution

Try something like this

C#
@{

  var grid = new WebGrid(Model);

    @grid.GetHtml(columns: grid.Columns(grid.Column(null,null, format: @<input type="hidden" name="IDHidden" value="@item.IDHidden"/>),

                                                             grid.Column("Title", "Title")));

}
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900