Hello,
I'm starting with ASP.Net MVC and I was working with the article:
http://help.infragistics.com/NetAdvantage/jQuery/2012.1/CLR4.0?page=igGrid.html
However I did not get a result out of this sample: my grid is not displayed:
my biggest problem is the datasourceurl: "BindGridFiltering" -> where is this action method;
i also tried datasource, but the grid was not displayed.
Perhaps you could send me an MVC sample for showing basis datasource for igGrid.
Thank you.
Model:
public class GridFilteringModel { public GridFilteringModel() { //The GridModel class holds all the properties for the MVC grid. GridFiltering = new Infragistics.Web.Mvc.GridModel(); }
public Infragistics.Web.Mvc.GridModel GridFiltering { get; set; } }
Controller:
<ActionName("Filtering")> Public Function GridFiltering() As ActionResult ' Zweck: GridFiltering Try DIm model As New GridFilteringModel() model.GridFiltering.DataSourceUrl = Url.Action("BindGridFiltering") model.GridFiltering.Height = "500px" model.GridFiltering.Columns.Add(new GridColumn("Autokennzeichen", "Autokennzeichen", "string", "300px")) model.GridFiltering.Columns.Add(new GridColumn("Bemerkung", "Bemerkung", "string", "205px")) Dim Filtering As new GridFiltering() model.GridFiltering.Features.Add(Filtering)
Return View(model)
Catch ex As Exception __Context.Prot.Err(ex) Throw ex End Try End Function
view:
@Html.Infragistics.Grid("grid1", Model.GridFiltering)
I am just following up to see if you have any assistance with this matter.
As per my understanding the images are missing in you application. I would suggest you to use IE Developer toolbar or firebug to find out what styles are missing. Refer to the link below that will give you download and more details on debugging tool:
<http://www.microsoft.com/download/en/details.aspx?id=18359>
<http://getfirebug.com/>
Additional Note: The above links are neither created nor maintained by Infragistics.
I hope this helps.
But in my grid the filter line has no "icons" (e.g. the filter symbol and the "<",">","=" icons)
What is missing ? a refernce to a icon library ?
I did the css and javascript references as shown in the examples.
I am just following if you need any further assistance with this matter.
Thank you for the update. Here is the VB syntax for the View:
@(Html.Infragistics().Grid(Of Employee)().ID("EmpGrid").PrimaryKey("Id") _ .Columns(Function(column) column.[For](Function(x) x.Id).DataType("string").HeaderText("Id") column.[For](Function(x) x.Name).DataType("string").HeaderText("Name") column.[For](Function(x) x.JobId).DataType("string").HeaderText("JobId") End Function).DataSourceUrl(Url.Action("GetEmployee")) _ .Width("100%").Height("350px") _ .AutoGenerateColumns(False).ClientDataSourceType(ClientDataSourceType.JSON).DataBind().Render() ))