Telerik Forums
UI for ASP.NET AJAX Forum
4 answers
193 views

Hi Team,

I have an issue with RadCombobox.
Currently we are using Telerik Version - 2015.3.1111.35 and Upgraded .NetFramework 3.5 to .NetFramework 4.8.

Tested in IE,edge and chrome - Not working.

Radcombobox dropdown click events are not firing after apppool changed to 4.0 for the first postback and 

It works for other controls in further postbacks.

Can anyone please help on this?

 


Vessy
Telerik team
 answered on 10 May 2021
1 answer
117 views

I'm creating a RadGrid dynamically and inserting a RadGrid into it.

When I change the RadGrid page, it disappears. How to keep the RadPageView content through Postback?

Besides that, none of RadGrid events are fired when the page changes.

My code:


<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="PageViewProblem.aspx.cs" Inherits="WebApp.PageViewProblem" %>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <telerik:RadTabStrip runat="server" ID="radTabStrip1" MultiPageID="radMultiViewSearchResult"></telerik:RadTabStrip>
            <telerik:RadMultiPage runat="server" ID="radMultiView1" SelectedIndex="0" EnableViewState="true"></telerik:RadMultiPage>
            <telerik:RadScriptManager ID="RadScriptManager1" runat="server"></telerik:RadScriptManager>
        </div>
    </form>
</body>
</html>


using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Telerik.Web.UI;

namespace WebApp
{
    public partial class PageViewProblem : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                LoadData();
            }
        }

        private void LoadData()
        {
            RadTab tab1 = new Telerik.Web.UI.RadTab("Tab1");
            radTabStrip1.Tabs.Add(tab1);
            RadPageView resultPageView1 = new RadPageView();
            resultPageView1.ID = "radPageView1";
            radMultiView1.PageViews.Add(resultPageView1);

            RadGrid grid1 = new RadGrid();
            grid1.ID = "RadGrid1";
            grid1.PageSize = 5;
            grid1.AllowPaging = true;
            grid1.AllowCustomPaging = true;
            grid1.PagerStyle.AlwaysVisible = true;
            grid1.VirtualItemCount = 50;
            grid1.NeedDataSource += (sender, args) =>
            {
                grid1.DataSource = SimulateDataSource(grid1);
            };
            grid1.PageIndexChanged += (sender , args) =>
            {
                Debug.WriteLine("Please, load page number: {grid1.currentPage}");
            };
            resultPageView1.Controls.Add(grid1);
        }

        private object SimulateDataSource(RadGrid grid)
        {
            List<ItemData> result = new List<ItemData>();
            for (int i = grid.CurrentPageIndex + 1; i <= grid.CurrentPageIndex + 5; i++)
            {
                result.Add(new ItemData(i, $"Item Description {i}"));
            }
            return result;
        }
        private class ItemData
        {
            public int Value { get; set; }
            public string Description { get; set; }
            public ItemData(int value, string description)
            {
                this.Value = value;
                this.Description = description;
            }
        }
    }
}

Attila Antal
Telerik team
 answered on 07 May 2021
1 answer
91 views
Hello, I am having problems running RadClientDataSource (data is loaded into RadMultiColumnComboBox) and KendoGrid on the same page. I get strange Ajax and Kendo errors in console about stuff being undefined. Are there any known incompatibilities between some Telerik UI controls and Kendo UI widgets? Are there controls that prefer external jQuery over internal one bundled in Telerik UI?
Peter Milchev
Telerik team
 updated answer on 07 May 2021
2 answers
721 views

When my RadGrid is exported to Excel, if one of the cell's data begins with a dash (-), I get the error message "Excel cannot open the file because the file format or file extension is not valid..." see in the attached Error.png.  If I remove leading dashes from the data by updating the database, or remove leading dashes in code before binding it to the grid, the grid exports as expected.  However this is not an sustainable or ideal solution.

- I have tried setting the excel export to Xlsx, Html, Biff and ExcelIML in both cs code and in the designer (also tried each independent of each other):

            AuthGrid.ExportSettings.Excel.Format = GridExcelExportFormat.Xlsx;
            AuthGrid.MasterTableView.ExportToExcel();

            <ExportSettings>
                <Excel FileExtension="xlsx" Format="Xlsx" />
            </ExportSettings>

- I have tried notes.DataFormatString = "{0}"; and notes.DataFormatString = "&nbsp;{0}";

I started with a slightly older version of these dlls, but also tried upgrading to newer versions:

- Telerik.Web.Spreadsheet version 2016.3.913.40 (upgraded to 2018.3.620.40)

- Telerik.Web.UI version 2016.3.914.45 (upgraded to 2018.2.710.45)

- Telerik.Web.UI.Skins version 2016.3.914.45 (upgraded to 2018.2.710.45)

- Telerik.Windows.Documents.Core version 2016.3.913.40 (upgraded to 2018.2.619.40)

- Telerik.Windows.Documents.Fixed version 2016.3.913.40 (upgraded to 2018.2.619.40)

- Telerik.Windows.Documents.Flow version 2016.3.913.40 (upgraded to 2018.2.619.40)

- Telerik.Windows.Documents.Spreadsheet version 2016.3.913.40 (upgraded to 2018.2.619.40)

- Telerik.Windows.Documents.Spreadsheet.FormatProviders.OpenXML version 2016.3.913.40 (upgraded to 2018.2.619.40)

- Telerik.Windows.Zip  version 2016.3.913.40 (upgraded to 2018.2.619.40)

Edward
Top achievements
Rank 1
Veteran
Iron
Iron
 answered on 06 May 2021
1 answer
209 views

Dear all,

 

I have the below radgrid defininition in my aspx page in which the selectionColumn is a checkbox. When I click on row, the postback is fired and I can calculate the sum of all selected rows and then display the results in the footer.

However when I click on the header checkbox, then all the lines are selected but the postback event is not fired.

Which property should be enable? Or maybe should it be managed differently?

My goal is to display in the footer, the sum of selected rows whatever it is by selection some specific rows or by using the select/unselect all checkbox.

Thanks

 

                                    <MasterTableView ShowFooter="true" DataKeyNames="ID" PageSize="50">
                                        <Columns>
                                            <telerik:GridClientSelectColumn HeaderStyle-Width="50px"></telerik:GridClientSelectColumn>
                                            <telerik:GridBoundColumn DataField="ID" FilterControlAltText="Filter on Chunk Key" HeaderText="Chunk Key" UniqueName="ID" HeaderStyle-Width="100px">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="PurchaseContract" FilterControlAltText="Filter on Purchase Ctr" HeaderText="Purchase Ctr" UniqueName="PurchaseContract" HeaderStyle-Width="150px">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="Supplier" FilterControlAltText="Filter on Supplier" HeaderText="Supplier" UniqueName="Supplier">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="ShipmentStatus" FilterControlAltText="Filter on Ship. Status" HeaderText="Ship.Status" UniqueName="ShipmentStatus">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="ShipmentDate" FilterControlAltText="Filter on Ship. Date" HeaderText="Ship. Date" UniqueName="ShipmentDate" DataFormatString="{0:dd/MM/yyyy}">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="ShipmentRef" FilterControlAltText="Filter on Ship. Ref" HeaderText="Ship. Ref" UniqueName="ShipmentRef" HeaderStyle-Width="250px">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="FinancingBank" FilterControlAltText="Filter on Financing Bank" HeaderText="Financing Bank" UniqueName="FinancingBank">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="FinancingRef" FilterControlAltText="Filter on Financing Ref." HeaderText="Financing Ref." UniqueName="FinancingRef">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="NetWeight" FilterControlAltText="Filter on NetWeight" HeaderText="Net Weight" UniqueName="NetWeight" HeaderStyle-HorizontalAlign="Right" ItemStyle-HorizontalAlign="Right" FooterStyle-HorizontalAlign="Right">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="Warehouse" FilterControlAltText="Filter on Warehouse" HeaderText="Warehouse" UniqueName="Warehouse">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="CustomsStatus" FilterControlAltText="Filter on CustomsStatus" HeaderText="Customs Status" UniqueName="CustomsStatus">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="Customer" FilterControlAltText="Filter on Customer" HeaderText="Customer" UniqueName="Customer">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="SaleContract" FilterControlAltText="Filter on SaleContract" HeaderText="Sale Ctr" UniqueName="SaleContract">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="SaleInvoiceNb" FilterControlAltText="Filter on SaleInvoiceNb" HeaderText="Sale Invoice Nb" UniqueName="SaleInvoiceNb">
                                            </telerik:GridBoundColumn>
                                            <telerik:GridBoundColumn DataField="Vessel" FilterControlAltText="Filter on Vessel" HeaderText="Vessel" UniqueName="Vessel">
                                            </telerik:GridBoundColumn>
                                        </Columns>
                                    </MasterTableView>
                                    <ClientSettings EnableRowHoverStyle="true" EnablePostBackOnRowClick="true">
                                        <Scrolling AllowScroll="True" UseStaticHeaders="True" SaveScrollPosition="true" FrozenColumnsCount="0"></Scrolling>
                                        <Selecting AllowRowSelect="true"></Selecting>
                                    </ClientSettings>
                                    <PagerStyle AlwaysVisible="true" Mode="NumericPages" Position="Bottom" />
                                </telerik:RadGrid>

 

Attila Antal
Telerik team
 answered on 06 May 2021
1 answer
86 views

Hello,

I'm currently working on a project where I have a RadGrid displaying some data. The filter functionality is already implemented and I've created a custom skin from an existing embedded skin for the GridDateTimeColumn and implemented according to the documentation here. Everything works perfect except that upon adding the <FilterTemplate> and setting the custom skin for the <telerik:RadDatePicker> the filter button it's not generated anymore. I've inspected the page and indeed the button is not just hidden with CSS or missing it's icon, it's not present at all in the HTML and the result is in the pictures attached.

Here is the markup I'm using.

<telerik:GridDateTimeColumn DataField="foo" UniqueName="foo" HeaderText="foo" PickerType="DatePicker" DataFormatString="{0: MM/dd/yyyy}" FilterDateFormat="MM/dd/yyyy" ReadOnly="true">
     <HeaderStyle Width="130" Font-Bold="true" />
          <FilterTemplate>
               <telerik:RadDatePicker runat="server" Skin="MyCustomSkin" EnableEmbeddedSkins="false"></telerik:RadDatePicker>
          </FilterTemplate>
 </telerik:GridDateTimeColumn>

Once I remove the <FilterTemplate> and return the skin to default the Filter button is displayed. I've looked for solutions but I couldn't seem to find any. What's causing this behaviour? Is it something I'm missing? 

 

Attila Antal
Telerik team
 answered on 05 May 2021
1 answer
165 views

Hi.

I'm using TooltipsAppearance.ClientTemplate. It's working fine but it's inheriting the standard tooltip appearance and my template appears inside it.

Please refer to the attached image.

An example of what the tooltip should look like is also in the image. You will also notice the text in the bottom half of the tooltip is not showing. It is actually there but the text color is white so you can't see it. 

What am I doing wrong?

Thanks.

Peter Milchev
Telerik team
 answered on 04 May 2021
1 answer
103 views

On the grouping demo page, I'm wondering if there's a bug.

When looking at the contents of the grouped combobox list, the grouping label of Argentina is shown as a column header instead of the black text to the right side.

Peter Milchev
Telerik team
 answered on 04 May 2021
2 answers
766 views

My radmultiselect has many values along with the option "None". The user is allowed to select up to 5 values and currently can select None amongst those 5 values which doesn't make any sense. If the user selects None (88 in the code below), I would like to clear any other selections and reselect None (88). I currently have the following code, but I can't figure out how to actually select or deselect an item via javascript.

ASP.NET:

<telerik:RadMultiSelect ID="RadMultiSelect1" runat="server" DataValueField="value" DataTextField="text" RenderMode="Lightweight" Placeholder="Select..." AutoClose="false" Skin="Bootstrap" CssClass="radmultiselectstyle" TagMode="Single" Width="100%" AccessKey="B">
          <ClientEvents OnSelect="onSelect" />
</telerik:RadMultiSelect>


JS:

<script type="text/javascript" id="telerikClientEvents1">
    function onSelect(sender, args) {
        var data = args.get_dataItem();
        var multiSelectObject = $find("<%=RadMultiSelect1.ClientID %>");
        var kendoMultiSelect = multiSelectObject.get_kendoWidget();
        if (data.value == '88') {
            /*[I would like to clear all values, reselect just 88, and, I'm guessing set 
the MaxSelectedItems to one unless 88 is deselected]*/ } } </script>

 

Can anyone help?

Thanks!

Peter Milchev
Telerik team
 answered on 04 May 2021
1 answer
167 views

I have two pages:

a.aspx
b.ascx

The goal is to get the RadToolBarButtons on b.ascx to fire the OnButtonClick() event as defined in the RadToolBar .

a.aspx is the host page for b.ascx and has this placeholder for different RadGrids:

<div id="divMiniGrid" runat="server" visible='<%# ActiveViewID != "viewFees" %>' class="rightPane">
         <sf:PaymentDetailsGrid ID="ctlMiniGrid" runat="server" class="rightPane" Visible="false" IsCondensed="true" />
</div>


b.ascx has the actual RadGrid that is loaded in a.aspx. The RadGrid has an ItemTemplated RadToolbar:

 <telerik:RadGrid ...>
    <MasterTableView ...>
        <CommandItemTemplate>
            <telerik:RadToolBar ... OnButtonClick="PaymentDetailsToolbar_ButtonClick" EnableViewState="true"  onClientButtonClicking="ClientButtonClicking" ...>
                <Items>
                    <telerik:RadToolBarButton runat="server" Text="Edit" ImageUrl="../images/icons/refresh.svg" CommandName="Edit" Enabled="False" />



The PaymentDetailsToolbar_ButtonClick() event lives on b.ascx, but it is never fired when the RadToolBarButton is clicked. Here's the signature:

protected void PaymentDetailsToolbar_ButtonClick(object sender, Telerik.Web.UI.RadToolBarEventArgs e){...}

The only event that is fired is a.aspx Page_Load() event when the RadToolBarButton is clicked. What's going on?

Attila Antal
Telerik team
 answered on 04 May 2021
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?