Telerik Forums
UI for ASP.NET AJAX Forum
1 answer
278 views

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>

Doncho
Telerik team
 answered on 06 Mar 2023
9 answers
620 views
Hi friends,
       In my page i used radtreeview and binded this radtreeview dynamically with database. when i click on expand symbol (+) radtreeview  not expanding. when i click on root node (AF - Angel Falls) it's working fine. Root node expand not working at first time after that it's working fine.

Please find the screen shot of my radtreeview and please provide me the solution.


Thanks,
Nagendra.
Prof. Francisco Araújo
Top achievements
Rank 2
Iron
 updated answer on 04 Mar 2023
0 answers
539 views
Hi,
   We try to export date from rad grid to excel using following code(Rad Grid Export Code), if have small data no problem, but having 10000+ data getting too long like 20 to 30 minutes to wait. Here i share my code for export.
radgrdcount.ExportSettings.FileName = filename
radgrdcount.ExportSettings.IgnorePaging = True
radgrdcount.ExportSettings.ExportOnlyData = True
radgrdcount.ExportSettings.OpenInNewWindow = True
radgrdcount.MasterTableView.ExportToExcel()
Any way to speed up the process ? Please replay asap

Thanks
M Kumar
Top achievements
Rank 1
Iron
Iron
Veteran
 updated question on 03 Mar 2023
1 answer
144 views

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>

Rumen
Telerik team
 answered on 02 Mar 2023
0 answers
162 views
Telerik RadCombobox OnClientTemplateDataBound not fired when the web service returns no data. Is there any function or method to resolve this issue?
KBIY
Top achievements
Rank 1
 asked on 01 Mar 2023
9 answers
140 views
I have a combobox on my form with load on demand.

Simply putting that combo box on my page has turned a page that was pretty instantaneous to a page that takes five seconds to load.

If firefox it works like a champ.  In IE7, I get the five second delay.

Do you guys have an IE7 fix for this issue?

EDIT:  I meant IE7.  I can't change the post title...
Alan
Top achievements
Rank 1
Iron
 updated answer on 01 Mar 2023
1 answer
341 views

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);
            }
        }


Mark
Top achievements
Rank 2
Iron
Iron
Iron
 answered on 27 Feb 2023
15 answers
995 views
hi ,
  I am using rad controld for asp.net ajax and use radgrid for self reference heirarchy. All working nice.
But now i want to hide the built in collapse / expand button when not have child view in the row. How can i achive this?
Eldhose
Top achievements
Rank 1
Iron
 updated answer on 20 Feb 2023
0 answers
159 views

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.

Chuck
Top achievements
Rank 1
 asked on 18 Feb 2023
0 answers
104 views

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

Hugo Augusto
Top achievements
Rank 2
Iron
Veteran
Iron
 asked on 17 Feb 2023
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?