I tried this code to filter radgrid from the external radcombox located outside the Grid. And i have a problem with it. Visual Studio debugger and SQL Profiler show that this code works and send to radgrid correct filter expression with the correct filter value. But radgrid doesn't filtrate data with this expression while rebinding. It shows all data without any filtering after rebinding. How can I solve it?
This is my code C#:
protected
void
RadComboBox1_SelectedIndexChanged(
object
sender, RadComboBoxSelectedIndexChangedEventArgs e)
{
radgrid.MasterTableView.FilterExpression =
"[service_id] LIKE '%"
+ ddlService.SelectedValue +
"%' "
;
GridColumn column = radgrid.MasterTableView.GetColumnSafe(
"serv_id"
);
column.CurrentFilterFunction = GridKnownFunction.EqualTo;
column.CurrentFilterValue = ddlService.SelectedValue;
column.AndCurrentFilterFunction = GridKnownFunction.EqualTo;
radgrid.MasterTableView.Rebind();
}
This is my code ASPX:
<
telerik:RadComboBox
ID
=
"ddlService"
runat
=
"server"
Height
=
"200"
Width
=
"240"
DropDownWidth
=
"310"
DataSourceID
=
"dsServices"
EmptyMessage
=
"- Select Product -"
HighlightTemplatedItems
=
"true"
CausesValidation
=
"false"
Filter
=
"Contains"
AppendDataBoundItems
=
"true"
onselectedindexchanged
=
"RadComboBox1_SelectedIndexChanged"
SelectedValue='<%# radgrid.MasterTableView.GetColumn("serv_id").CurrentFilterValue %>'
AllowCustomText="true" AutoPostBack="true" DataTextField="service_name" DataValueField="id"
>
I tried this code to filter radgrid from the external radcombox located outside the Grid. And i have a problem with it. Visual Studio debugger and SQL Profiler show that this code works and send to radgrid correct filter expression with the correct filter value. But radgrid doesn't filtrate data with this expression while rebinding. It shows all data without any filtering after rebinding. How can I solve it?
This is my code C#:
protected
void
RadComboBox1_SelectedIndexChanged(
object
sender, RadComboBoxSelectedIndexChangedEventArgs e)
{
radgrid.MasterTableView.FilterExpression =
"[service_id] LIKE '%"
+ ddlService.SelectedValue +
"%' "
;
GridColumn column = radgrid.MasterTableView.GetColumnSafe(
"serv_id"
);
column.CurrentFilterFunction = GridKnownFunction.EqualTo;
column.CurrentFilterValue = ddlService.SelectedValue;
column.AndCurrentFilterFunction = GridKnownFunction.EqualTo;
radgrid.MasterTableView.Rebind();
}
This is my ASPX code with combox setting:
<
telerik:RadComboBox
ID
=
"ddlService"
runat
=
"server"
Height
=
"200"
Width
=
"240"
DropDownWidth
=
"310"
DataSourceID
=
"dsServices"
EmptyMessage
=
"- Select Product -"
HighlightTemplatedItems
=
"true"
CausesValidation
=
"false"
Filter
=
"Contains"
AppendDataBoundItems
=
"true"
onselectedindexchanged
=
"RadComboBox1_SelectedIndexChanged"
SelectedValue='<%# radgrid.MasterTableView.GetColumn("serv_id").CurrentFilterValue %>'
AllowCustomText="true" AutoPostBack="true" DataTextField="service_name" DataValueField="id"
>
I tried this code to filter radgrid from the external radcombox located outside the Grid. And i have a problem with it. Visual Studio debugger and SQL Profiler show that this code works and send to radgrid correct filter expression with the correct filter value. But radgrid doesn't filtrate data with this expression while rebinding. It shows all data without any filtering after rebinding. How can I solve it?
This is my code C#:
protected
void
RadComboBox1_SelectedIndexChanged(
object
sender, RadComboBoxSelectedIndexChangedEventArgs e)
{
radgrid.MasterTableView.FilterExpression =
"[service_id] LIKE '%"
+ ddlService.SelectedValue +
"%' "
;
GridColumn column = radgrid.MasterTableView.GetColumnSafe(
"serv_id"
);
column.CurrentFilterFunction = GridKnownFunction.EqualTo;
column.CurrentFilterValue = ddlService.SelectedValue;
column.AndCurrentFilterFunction = GridKnownFunction.EqualTo;
radgrid.MasterTableView.Rebind();
}
This is my ASPX code with combox setting:
<
telerik:RadComboBox
ID
=
"ddlService"
runat
=
"server"
Height
=
"200"
Width
=
"240"
DropDownWidth
=
"310"
DataSourceID
=
"dsServices"
EmptyMessage
=
"- Select Product -"
HighlightTemplatedItems
=
"true"
CausesValidation
=
"false"
Filter
=
"Contains"
AppendDataBoundItems
=
"true"
onselectedindexchanged
=
"RadComboBox1_SelectedIndexChanged"
SelectedValue='<%# radgrid.MasterTableView.GetColumn("serv_id").CurrentFilterValue %>'
AllowCustomText="true" AutoPostBack="true" DataTextField="service_name" DataValueField="id"
>
I have a subgrid within which there is a button to add a row (record).
When the button to add a row is clicked, then the below function is called:
function vAddRow(e) {
var grid = $(e.parentElement.parentElement).data("kendoGrid")
;
parentId = grid.element[0].id.split("-")[2];
grid.addRow();
console.log("vet add row");
};
When this function is called the console shows the error "TypeError: t is undefined ". From what I can see this error is triggered from the Kendo source within the "addRow" function.
I cannot find anything in the documentation that defines what "T" is within the context of addRow.
I don't know how relevant it is but the parent grid has the same functionality and does not encounter an error.
Any insight would be great!
I feel like I must be missing something very obvious. I have this:
<
telerik:RadClientDataSource
ID
=
"RadClientDataSource1"
runat
=
"server"
AllowBatchOperations
=
"true"
ClientEvents-OnRequestStart
=
"RequestStart"
ClientEvents-OnRequestEnd
=
"ResponseEnd"
>
<
DataSource
>
<
WebServiceDataSourceSettings
>
<
Select
DataType
=
"JSON"
/>
</
WebServiceDataSourceSettings
>
</
DataSource
>
<
Schema
>
<
Model
ID
=
"DialogIDChecksum"
>
..
<
telerik:ClientDataSourceModelField
FieldName
=
"ConferenceDateTime"
DataType
=
"Date"
/>
..
</
Model
>
</
Schema
>
<
SortExpressions
>
<
telerik:ClientDataSourceSortExpression
FieldName
=
"ConferenceDateTime"
SortOrder
=
"Desc"
/>
</
SortExpressions
>
</
telerik:RadClientDataSource
>
And it is tied to a RadGrid. Everything loads perfectly but it's not sorted. Is there something special I need to do in the RadGrid so it uses the SortExpressions object in the RadClientDataSource?
Thanks,
Richard