Iam using telerik grid of asp.net
I want to disable column "telerik:GridNumericColumn " in below code snippet on changing "telerik:GridDropDownColumn" I am not aware of how to handle selection change event of GridDropDownColumn on server side and make one column disabled.
Please help in this regard.
Regards, Kiran
Below is the radgrid declaration
<telerik:RadGrid ID="rg" runat="server"
AllowSorting="False"
AutoGenerateColumns="False" Width="730px" Height="263px"
OnUpdateCommand="rg_Update"
OnInsertCommand="rg_Insert"
OnDeleteCommand="rg_Delete"
OnItemCreated="rg_ItemCreated"
OnItemCommand="rg_ItemCommand"
OnSelectedIndexChanged="rg_SelectedIndexChanged"
OnNeedDataSource="rg_NeedDataSource"
OnDataBound="rg_DataBound"
GridLines="None"
CellSpacing="0"
MasterTableView-Caption="Routing Rules">
<ClientSettings AllowKeyboardNavigation="true" EnablePostBackOnRowClick="true">
<Scrolling AllowScroll="True" UseStaticHeaders="True" />
<Selecting AllowRowSelect="True" />
</ClientSettings>
<MasterTableView CommandItemDisplay="Top" DataKeyNames="Id,IndexId">
<CommandItemSettings AddNewRecordText="Add New Routing Rule" />
<Columns>
<telerik:GridButtonColumn UniqueName="editButton" ButtonType="ImageButton" CommandName="Edit" FilterControlAltText="Filter editButton column"
HeaderText="Edit" HeaderStyle-Width="34px" ItemStyle-HorizontalAlign="Left" Resizable="false"
ImageUrl="~\Images\pencil.png">
</telerik:GridButtonColumn>
<telerik:GridButtonColumn UniqueName="deleteButton" ButtonType="ImageButton" CommandName="Delete" FilterControlAltText="Filter deleteButton column"
HeaderText="Delete" HeaderStyle-Width="47px" ItemStyle-HorizontalAlign="Left" Resizable="false"
ImageUrl="~\Images\delete.png"
ConfirmDialogType="RadWindow" ConfirmText="Are you sure you want to delete this record?">
</telerik:GridButtonColumn>
<telerik:GridBoundColumn Visible="false" DataField="Id" UniqueName="RoutingRuleRuleId" ReadOnly="True" />
<telerik:GridNumericColumn DataField="Priority" UniqueName="RoutingRulePriority" HeaderText="Priority" DataType="System.Int32" MaxLength="3" />
<telerik:GridDropDownColumn
HeaderText="Rule Type" DataField="RoutingRuleDefinitionId" SortExpression="uRuleType" UniqueName="uRuleType"
ColumnEditorID="myRuleTypeDropDownEditor"
ListTextField="Name" ListValueField="Id" EnableEmptyListItem="True"
EmptyListItemValue="0" Visible="False">
</telerik:GridDropDownColumn>
</MasterTableView>
</telerik:RadGrid>
radgrdcount.ExportSettings.FileName = filename radgrdcount.ExportSettings.IgnorePaging = True radgrdcount.ExportSettings.ExportOnlyData = True radgrdcount.ExportSettings.OpenInNewWindow = True radgrdcount.MasterTableView.ExportToExcel()
Hello telerik,
This is my first time using the telerik. I want to know how to add the following judgments in JavaScript or events. And also remove the image which does not fit the criteria at the same time.
For example, I need type in a text box '123' and upload an image called '123.jpg', then it is allowed to upload, because '123'='123'.But if I type in a text box '123' and upload an image called 'abc.jpg', it is not allowed to upload, because '123'<>'abc', then auto remove the image and reselect. how can I do it, please help me.
the following is my code.
<telerik:RadTextBox ID="txtContainer" runat="server" OnTextChanged ="txtContainer_TextChanged" AutoPostBack ="true" ></telerik:RadTextBox>
<telerik:RadAsyncUpload RenderMode="Lightweight" runat="server" ID="AsyncUpload1" AllowedFileExtensions="jpeg,jpg,gif,png,bmp" OnFileUploaded="RadAsyncUpload1_FileUploaded1" OnClientValidationFailed="onClientValidationFailed" MaxFileInputsCount="1" > </telerik:RadAsyncUpload>
<script type="text/javascript">
function onClientValidationFailed(sender, args) {
$telerik.$(".ruCancel").parent().remove();
alert("Allowed files extension is jpeg,jpg,gif,png,bmp");
sender.addFileInput();
}
</script>

This is exactly what I need. But then I tried it. Now my radgrid does not filter at all. It is something in the prerender.. if I remove this.
Then filtering works again. Is there something that I am missing? It is like the preRender is canceling out my filter. I am using a needdatasource
https://docs.telerik.com/devtools/aspnet-ajax/knowledge-base/grid-save-and-restore-the-filters-automatically
protected void grdProducts_PreRender(object sender, EventArgs e)
{
var grid = (RadGrid)sender;
// If the flag is True
if (IsFiltering)
{
// Save the Filters
SaveFilters(grid);
// Clear the Flag by setting its value to False
IsFiltering = false;
}
// At initial Load (when not is a PostBack)
if (!IsPostBack)
{
// Restore the Filters
RestoreFilters(grid);
}
}Is there any way to restrict the user from entering custom text into a databound multicolmncombobox. Forcing them to select an existing item. A dropdown list is not usable as it is bound to a table which has 5000 records. Some filtering based on a couple of fields is required.
Trying to use Lightweight mode but in current browsers it's now working properly and it's even unusable with RadTreeview. I even tried to use your ThemeBuilder but the online sample gives bad results also. Check the image from ThemeBuilder.
I'm using Windows 11, latest version of Edge.
Thank you