Jun 10, 2011, 10:59 AM
[CLOSED] Loading data in gridpanel through WebService in sublassed window
Hello,
I created subclassed ext.net window control and want use web service for populating gridpanel inside this window,
but grid not load data. I don't see what is wrong and where I made mistake.
This control I call in my page with following code:
Best regards,
Sasa
I created subclassed ext.net window control and want use web service for populating gridpanel inside this window,
but grid not load data. I don't see what is wrong and where I made mistake.
This control I call in my page with following code:
new Test.UI.TestWindow().Render(this.Page.Form.ClientID,RenderMode.RenderTo);
Code for subclassed window control is following:namespace Test.UI
{
public class TestWindow : Ext.Net.Window
{
public TestWindow()
{
this.IDMode = IDMode.Explicit;
this.ID = "frmTest";
this.Width = 600;
this.Height = 600;
this.Layout = "FitLayout";
this.Padding = 5;
this.Items.Add(new GridPanel
{
ID = "gridCourses",
IDMode = IDMode.Explicit,
Height = 300,
AutoExpandColumn = "caption",
Store=
{
new Store
{
ID = "strCalcW",
IDMode = IDMode.Explicit,
RemoteSort = true,
Proxy =
{
new HttpProxy{Json=true,Method= HttpMethod.POST,Url="../Shared/GetStudyCourses.asmx/CoursePaging"}
},
AutoLoadParams =
{
new Parameter{Name="start",Value="0",Mode=ParameterMode.Raw},
new Parameter{Name="limit",Value="20",Mode=ParameterMode.Raw}
},
BaseParams =
{
new Parameter{Name="studycode",Value="SS",Mode=ParameterMode.Raw},
new Parameter{Name="semestar",Value="0",Mode=ParameterMode.Raw}
},
Reader =
{
new JsonReader
{
IDProperty="idrec",
Root = "d.Data",
TotalProperty="d.TotalRecords",
Fields=
{
new RecordField{Name="idrec"},
new RecordField{Name="caption"},
new RecordField{Name="studycode"}
}
}
},
SortInfo = { Field = "caption", Direction = SortDirection.ASC }
}
},
ColumnModel =
{
ID = "colCalcW",
IDMode = IDMode.Explicit,
Columns =
{
new RowNumbererColumn{Header="No.",Width=30,ColumnID="col1"},
new Column{Header="Caption",ColumnID="caption",DataIndex="caption",Sortable=true,MenuDisabled=true},
new Column{Header="",Width=30,ColumnID="col3",DataIndex="studycode",Sortable=true,MenuDisabled=true}
}
},
LoadMask = { ShowMask = true, Msg = "Loading..." },
SelectionModel = { new CheckboxSelectionModel { ID = "id", IDMode = IDMode.Explicit } },
BottomBar = { new PagingToolbar { PageSize = 20 } }
});
}
}
Please can you look what is wrong.Best regards,
Sasa
Last edited by Daniil; Jun 13, 2011 at 10:28 AM.
Reason: [CLOSED]