Telerik Forums
Community Forums Forum
0 answers
150 views
Hello guys. I updated my kendo-grid package version from 4.8.0 to 5.1.0. However, I am facing the following problem:


Does anyone know what can it be? Maybe is a storybook error?
ane
Top achievements
Rank 1
 asked on 08 Aug 2023
1 answer
70 views
Hi,

I need some insights on whether to move to React or stick with jQuery. Currently, we are using Kendo UI with jQuery, and we heavily rely on Kendo grid for its custom functionality in terms of filtering, views, selection, etc. I wonder if the same level of customization can be achieved with React or Vue?

I am asking the above question because our team is comfortable with jQuery, and they will need to learn either React or Vue if we decide to go down that path.
Zornitsa
Telerik team
 answered on 08 Aug 2023
1 answer
70 views

Could someone tell me why the loader control does not hide and stays in the dialog indefinitely? Even after fetching the data and toggling the visibility of the control to false? I noticed that it disappears only after zooming out of the browser?

Here is my simple code:

@page "/fetchdata"
@using Telerik.Blazor;
@using Telerik.Blazor.Components;
@using Telerik.DataSource;
@using Telerik.FontIcons
@using Telerik.SvgIcons;
@using Telerik.DataSource.Extensions;

<TelerikButton OnClick="@OpenDialogRequestHandler">Click me to open dialog</TelerikButton>

<TelerikDialog
    @bind-Visible="@DialogVisibility"
    ShowCloseButton="true"
    CloseOnOverlayClick="true"
    Title="Test"
    Height="300">
    <DialogContent>
        <TelerikLoaderContainer
            OverlayThemeColor="light"
            Visible="@(ApiDataRequestInProgress)"
            Class="initial-data-loader"
            LoaderType="@LoaderType.InfiniteSpinner"
            Size="@(ThemeConstants.Loader.Size.Medium)">
        </TelerikLoaderContainer>
        <TelerikGrid 
            EnableLoaderContainer="false"
            Sortable="true"
            OnRead="@GridReadHandler"
            TItem="TestObject"
            Height="500px" 
            Width="300px" Data="_testData" 
            SelectionMode="GridSelectionMode.Single">
            <GridColumns>
                <GridColumn Field="@nameof(TestObject.Gid)" Visible="false" Width="0" />
                <GridColumn Field="@nameof(TestObject.TestProperty)" Title="Treść" Width="100%" />
            </GridColumns>
        </TelerikGrid>
    </DialogContent>
</TelerikDialog>

@code {
    bool _dataInitiated = false;
    bool _refreshing = false;
    List<TestObject> _testData = new List<TestObject>();

    async Task GridReadHandler(GridReadEventArgs args)
    {
        if (!_dataInitiated)
        {
            // I don't want to download data in the OnInitialized method because if the form contains a
            // lot of such fields, the page loading will slow down terribly. And this data is only needed
            // if the user opens a dialog box (clicks a button). Otherwise there is no point in downloading them.
            await MakeAPIRequestAsync();
            _dataInitiated = true;
        }

        DataSourceResult result = _testData.ToDataSourceResult(args.Request);
        args.Data = result.Data;
        args.Total = result.Total;
        StateHasChanged();
    }

    void OpenDialogRequestHandler()
    {
        DialogVisibility = true;
    }

    async Task MakeAPIRequestAsync(bool pCzyNieUzywacCache = false)
    {
        try
        {
            // Simulate API request
            await Task.Delay(1000);

            _testData.Clear();
            _testData.Add(new TestObject() { TestProperty = "Alice" });
            _testData.Add(new TestObject() { TestProperty = "Has" });
            _testData.Add(new TestObject() { TestProperty = "A" });
            _testData.Add(new TestObject() { TestProperty = "Cat" });
        }
        finally
        {
            ApiDataRequestInProgress = false;
        }
    }

    public bool ApiDataRequestInProgress { get; set; } = true;

    public bool DialogVisibility { get; set; } = false;

    internal class TestObject
    {
        public Guid Gid { get; set; } = Guid.NewGuid();
        public string TestProperty { get; set; } = string.Empty;
    }
}

Nadezhda Tacheva
Telerik team
 answered on 08 Aug 2023
1 answer
64 views

I'm currently working on a data science project using Python's Pandas library, and I've encountered an issue with missing values in my DataFrame. My dataset contains various columns, and some of them have missing values represented as NaN.

Here's a snippet of my DataFrame:


import pandas as pd

# Sample DataFrame with missing values
data = {
    'Name': ['Alice', 'Bob', 'Charlie', 'David', 'Eva'],
    'Age': [25, 28, None, 32, 22],
    'Score': [85, None, 78, 92, None],
    'Salary': [50000, 60000, 55000, None, 48000]
}

df = pd.DataFrame(data)

I want to handle these missing values effectively before proceeding with my analysis. I'm considering a few options like removing rows with NaN, imputing the missing values with the mean, or using interpolation.

I've been seeking assistance from the scalers data science project website, but I've been unable to find the answer. I would appreciate some advice on how to handle missing values in my DataFrame. I would also welcome some code samples that show how the selected method is implemented. I appreciate your assistance in advance!

Nikolay
Telerik team
 answered on 02 Aug 2023
1 answer
93 views

Hello

I would like to delete the Telerik user account but I couldn't find any hints on how to do this.

Thanks

Christian
Top achievements
Rank 1
 answered on 31 Jul 2023
1 answer
46 views
i am try to import rtf file with header and footer images it throw the following error,

   at System.ThrowHelper.ThrowKeyNotFoundException()
   at System.Collections.Generic.Dictionary`2.get_Item(TKey key)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.Elements.Lists.HtmlExportListManager.ShouldRestartLevel(List list, Int32 listLevelIndex)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.HtmlContentManager.<ExportParagraph>d__1f.MoveNext()
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.HtmlContentManager.<ExportBlockContainer>d__b.MoveNext()
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.Elements.BodyElement.<OnEnumerateInnerElements>d__0.MoveNext()
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.Elements.HtmlElementBase.WriteContent(IHtmlWriter writer, IHtmlExportContext context)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.Elements.HtmlElementBase.Write(IHtmlWriter writer, IHtmlExportContext context)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.Elements.HtmlElementBase.WriteContent(IHtmlWriter writer, IHtmlExportContext context)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Model.Elements.HtmlElementBase.Write(IHtmlWriter writer, IHtmlExportContext context)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.Export.HtmlExporter.Export(IHtmlWriter writer, IHtmlExportContext context)
   at Telerik.Windows.Documents.Flow.FormatProviders.Html.HtmlFormatProvider.ExportOverride(RadFlowDocument document, Stream output)
   at Telerik.Windows.Documents.Common.FormatProviders.TextBasedFormatProviderBase`1.Export(T document)
   at Unite.Infrastructure.SQL.Repositories.ConsentRepository.GetHtmlFromDocument(RadFlowDocument document) in D:\WorkSpace\Unite2.0\Dev Branch\Unite\Unite.Infrastructure.SQL\Repositories\ConsentRepository.cs:line 337
6 answers
1.3K+ views
I don't remember signing up on this website so I'd like to delete my account, please help me
Dandre
Top achievements
Rank 1
 answered on 26 Jul 2023
1 answer
69 views

I created an account by signing in via Google. I've then followed the steps for adding the nuget feed to Visual Studio as described in https://docs.telerik.com/aspnet-mvc/installation/nuget-install#troubleshooting-issues-with-nuget. However, I'm unable to proceed past the Windows Authentication Dialog with my Google credentials.

Any ideas would be greatly appreciated.

Lance | Manager Technical Support
Telerik team
 answered on 24 Jul 2023
0 answers
63 views

Hello I have being looking for examples on  using auto complete using tag helpers  but coulnt find any 

in my grid column i have

        <column field="TechnicianAssigned" width="250" editor="categoryDropDownEditor" />

 

 and the categoryDropDownEditor has  code as below....the code hits the  url but not sure how to pass the data from column to  method and serach the functionality.Any example would be helpful.

 

   function categoryDropDownEditor(data) {
            $('<input data-bind="value: value" name="' + data.field + '"/>')
                .kendoAutoComplete({
                    dataSource: {
                        transport: {
                            read: {
                                url: "/Home/EmpSearchData",
                                dataType: "jsonp"
                            }
                        }
                    },
                    dataTextField: "ename",

                    filter: "contains",
                    minLength: 4
                });
        }
Rajesh
Top achievements
Rank 1
Iron
 asked on 19 Jul 2023
0 answers
29 views

I need to export my RadGrid, which displays correctly, to an Excel file. But when I click the Export To Excel button, it doesn't export. Instead, the entire Command Item bar disappears.

The same thing is happening on another RadGrid on the same page, but clicking the Export To Excel button also removes paging from the RadGrid, so that it displays all of the data.

Here is the markup for the second RadGrid:

    <telerik:RadGrid ID="rgPickedDetail" runat="server" AllowFilteringByColumn="False" AllowPaging="True" OnItemCommand="rgPickedDetail_ItemCommand"
        AllowSorting="True" DataSourceID="DetailDataSource" ShowStatusBar="True" PageSize="15" OnItemDataBound="rgPickedDetail_ItemDataBound"
        Skin="Telerik" AllowAutomaticUpdates="true" AutoGenerateColumns="False">
        <ExportSettings HideStructureColumns="true" Excel-Format="Xlsx" ExportOnlyData="true" IgnorePaging="true" />
        <PagerStyle Mode="NextPrevNumericAndAdvanced"></PagerStyle>
        <MasterTableView CommandItemDisplay="Top" HierarchyLoadMode="ServerOnDemand" AllowSorting="false" AutoGenerateColumns="false">
            <CommandItemSettings ShowExportToCsvButton="true" ShowExportToExcelButton="true" ShowAddNewRecordButton="false" ShowRefreshButton="true" />
            <Columns>
                <telerik:GridBoundColumn DataField="Plant" DataType="System.String" HeaderText="Plant" ReadOnly="True" UniqueName="Plant" />
                <telerik:GridBoundColumn DataField="PartNum" DataType="System.String" HeaderText="Part" ReadOnly="True" UniqueName="PartNum" />
                <telerik:GridBoundColumn DataField="SerialNum" DataType="System.String" HeaderText="Serial number" ReadOnly="True" UniqueName="SerialNum" />
                <telerik:GridBoundColumn DataField="QtyPicked" DataType="System.Int32" HeaderText="Picked" ReadOnly="True" UniqueName="QtyPicked" />
                <telerik:GridBoundColumn DataField="QtyReq" DataType="System.Int32" HeaderText="Requested" ReadOnly="True" UniqueName="QtyReq" />
                <telerik:GridBoundColumn DataField="Scanned" DataType="System.DateTime" DataFormatString="{0:M/d/yy HH:mm}" HeaderText="Scanned" ReadOnly="True" UniqueName="Scanned" />
                <telerik:GridBoundColumn DataField="FromLoc" DataType="System.String" HeaderText="From" ReadOnly="True" UniqueName="FromLoc" />
                <telerik:GridBoundColumn DataField="ToLoc" DataType="System.String" HeaderText="To" ReadOnly="True" UniqueName="ToLoc" />
                <telerik:GridBoundColumn DataField="Picked" DataType="System.Boolean" Display="false" HeaderText="Picked (invisible)" UniqueName="Picked" />
            </Columns>
        </MasterTableView>
    </telerik:RadGrid>

Here is the relevant code-behind:


    Shared ReportDate As Date

    Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
        If ReportDate = Nothing Then
            ReportDate = Today
            StartDate.SelectedDate = ReportDate
        End If
        SetReportDate()

        If Not Page.IsPostBack Then
        End If
    End Sub

    Protected Sub MessageBox(msg As String)
        ScriptManager.RegisterStartupScript(Me, Me.GetType, "WindowsScript", "alert('" + msg + "');", True)
    End Sub

    Protected Sub rgPickedDetail_ItemDataBound(sender As Object, e As GridItemEventArgs)
        If e.Item.GetType() Is GetType(GridDataItem) Then
            Dim item As GridDataItem = e.Item
            item.ForeColor = IIf(item("Picked").Text = "True", Color.Green, Color.Red)
        End If
    End Sub

    Protected Sub StartDate_SelectedDateChanged(sender As Object, e As Calendar.SelectedDateChangedEventArgs)
        ReportDate = e.NewDate
        SetReportDate()
        rgPickedSummary.Rebind()
        rgPickedDetail.Rebind()
    End Sub

    Private Sub SetReportDate()
        SummaryDataSource.SelectParameters("StartDate").DefaultValue = ReportDate
        DetailDataSource.SelectParameters("StartDate").DefaultValue = ReportDate
    End Sub

    Protected Sub rgPickedDetail_ItemCommand(sender As Object, e As GridCommandEventArgs)
        If e.CommandName = "ExportToExcel" Then
            rgPickedDetail.Rebind()
        End If
    End Sub

    Protected Sub rgPickedDetail_ItemCreated(sender As Object, e As GridItemEventArgs) Handles rgPickedDetail.ItemCreated
        If TypeOf e.Item Is GridCommandItem Then
            ScriptManager.GetCurrent(Page).RegisterPostBackControl(e.Item.FindControl("ExportToExcelButton"))
        End If
    End Sub

    Protected Sub rgPickedSummary_ItemCreated(sender As Object, e As GridItemEventArgs) Handles rgPickedSummary.ItemCreated
        If TypeOf e.Item Is GridCommandItem Then
            ScriptManager.GetCurrent(Page).RegisterPostBackControl(e.Item.FindControl("ExportToExcelButton"))
        End If
    End Sub
In my research, I have seen some people have problems like this when they are using Ajax, but my project has no references to Ajax inside it.
Lee
Top achievements
Rank 1
 asked on 19 Jul 2023
Top users last month
Dominik
Top achievements
Rank 1
Giuliano
Top achievements
Rank 1
Dominic
Top achievements
Rank 1
Glendys
Top achievements
Rank 1
NoobMaster
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?