Telerik Forums
UI for ASP.NET MVC Forum
1 answer
28 views

Hello Telerik support team,

 

I have an ASP.NET MVC project made in .NET Framework 4.6.2

It is using a local directory with files of version 2022.2.510 of Kendo UI. These are the contents of /lib/KENDOUIMVC/2022.2.510.545 of my project:

Kendo.Mvc.dll*  cs-CZ/            el-GR/   fr-FR/  pl-PL/  ru-RU/        tr-TR/
Kendo.Mvc.xml   da-DK/            es-ES/   he-IL/  pt-BR/  sk-SK/        uk-UA/
ar-AE/          de-DE/            export/  it-IT/  pt-PT/  spreadsheet/  zh-CN/
bg-BG/          distribution.xml  fr-CA/   nl-NL/  ro-RO/  sv-SE/

 

I want to make use of the DropDownButton component in this project, and I tried the example code from this page:

https://demos.telerik.com/aspnet-mvc/dropdownbutton

I get this error however:

'WidgetFactory<InvoiceFilterViewModel>' does not contain a definition for 'DropDownButton' and no accessible extension method 'DropDownButton' accepting a first argument of type 'WidgetFactory<InvoiceFilterViewModel>' could be found (are you missing a using directive or an assembly reference?)

So I believe the DropDownButton is not available yet in the version of Kendo that I am using.

 

My questions;

1. Is it possible to upgrade my version of Kendo in the same way as have already? I tried looking in the downloads section, but I don't see the bundle of files I need. The source code bundles contain many different files. If this is not possible, can you then please tell me the alternatives?

2. Is it possible to see which versions a component is supported for on the Telerik documentation website?

 

I already applied an alternative using the DropDownList, but this does not really satisfy the requirements as a DropDownButton would. Note that upgrading the .NET version of this project is (sadly) not a possibility for me at the moment.

 

And a little side note, it seems this link is broken when clicking on the red "Documentation" button:

Page with the button: https://www.telerik.com/aspnet-mvc/dropdownbutton 

Broken link: https://www.telerik.com/aspnet-mvc/documentation/getting-started 

Mihaela
Telerik team
 answered on 07 Aug 2025
1 answer
40 views

Hi,

I'm using ASP.NET MVC  with Kendo UI v. 2024.2.514 and I'm running into a weird issue when exporting a grid to PDF.

When I trigger the export, the PDF output shows only the current page of the grid duplicated X number of times.

For example, if I'm on page 2 of a 10-page grid, instead of exporting all ten pages, the PDF contains page 2 repeated 10 times.

I'm enabling the PDF export like this:

.ToolBar(tools => tools.Pdf())
.Pdf(pdf => pdf.AllPages())

Has anyone run into this issue or have any suggestions on what I'm missing here?

Thanks!

Mihaela
Telerik team
 answered on 07 Aug 2025
1 answer
55 views

Hi,

I am using Web app with mvc. We are using Deferred Script File to remediate CSP (content security policy). 

For that reason instead of Client Template i am using Client Template Handler for one of the column which is a dropdownlist.

Whenever Grid is loaded with data, I can see the selected dropdown values in the grid but when i try to update the dropdown value

its opening as a text box and showing value as [object object].

 

  columns.Bound(p => p.Studendetails).ClientTemplateHandler("getname") 

function getname(data) {
     return data.Studendetails ? data.Studendetails.Name : '';
 }

 

Mihaela
Telerik team
 answered on 05 Aug 2025
0 answers
20 views
Trying to use DragandDrop on 2 treeviews to drag from one tree to another. I believe I have all JS components loaded properly but still getting this error the tree data will load otherwise with DragandDrop set to false. Any help or direction would be appreciated.  Full Error can be seen below
jquery.min.js:2 Uncaught TypeError: d.HierarchicalDragAndDrop is not a constructor
    at init._dragging (kendo.treeview.js:2490:2)
    at new init (kendo.treeview.js:2490:2)
    at HTMLDivElement.<anonymous> (kendoLayout.min.js:1:42737)
    at ce.each (jquery.min.js:2:3129)
    at ce.each (jquery.min.js:2:1594)
    at ce.kendoTreeView (kendoLayout.min.js:1:42713)
    at HTMLDocument.<anonymous> (RolesPermissions:933:116)
    at e (jquery.min.js:2:27028)

James
Top achievements
Rank 1
 updated question on 04 Aug 2025
1 answer
27 views

Hello there,
i have a project with MVC Asp.Net, Kendo v. "2024.4.1112.462" and would like to
- load data into grid, the data is returned by MVC Controller
- the spinner with the "loading data in progress" should never appear
- so the user can "play" on the grid header filters while loading data is ongoing 
- when the user clicks on "apply" on grid header filter, the previous request must be canceled to run the new request with latest filters applied, in this way the c#  CancellationToken is Canceled on server side.

Can you tell me how to "cancel" the actual http request from the kendo grid (client) and execute the new one, as described in the last point?

thanks in advance

Anton Mironov
Telerik team
 answered on 30 Jul 2025
1 answer
28 views
Hi Team,

I am trying to make child/detail grid column as hyperlink but i am getting not defined error in  console.
Can you please guide on this?
Below is my code & PFA the error screenshot.

Thanks
Chandan Gupta

 columns.Bound(c => c.Inbound).ClientTemplate(
    "<a href='" +
    Url.Action("ReadFeedFile", "TreasuryFeeds") +
    "?fpath=\"#= Inbound #\"&archFileName=#=Archive#'" +
    ">#=Inbound#</a>"
).Title("File Name").Width(120).HtmlAttributes(new { style = "text-align:center;font-size: 10px;font-family: 'Segoe UI', Helvetica, 'Droid Sans', Tahoma, Geneva, sans-serif;" });

Eyup
Telerik team
 answered on 30 Jul 2025
1 answer
27 views

 

This is my code.

 

        

@using apexanalytix.app
@using apexanalytix.app.HtmlHelperExtensions
@using FirstStrike.VendorPortal.SharedDataContracts.VendorProfile
@using Kendo.Mvc.UI
@using Portal.BusinessObjects.Common;
@inject VendorProfileHelper vendorProfileHelper
@inject SysSettingHelper sysSettingHelper

@{
    var currentCulture = System.Globalization.CultureInfo.CurrentCulture.ToString();
}
<script>
    $(function () {

        kendo.culture("en-US");
    });
</script>
<style>
    .rowHighlighter {
        background-color: #ff0000;
        color: #fff !important;
    }
        .rowHighlighter:hover {
            background-color: #e95652 !important;
            color: #fff !important;
        }
    .rowHighlighter.k-state-selected {
            background-color: #009ec9 !important;
        }
     .rowHighlighter.k-state-selected td{
            background-color: #009ec9 !important;
        }
        .rowHighlighter td a {
            color: #fff !important;
        }
    .k-filter-row label > input[type=radio] {
        vertical-align: middle;
        position: relative;
        bottom: 2px;
        margin-left: 3px;
        margin-right: 10px;
    }

    .k-dropdown-wrap {
        max-height: 27px;
    }

    .k-grid td {
        line-height: 1em;
    }

    .k-grid .k-grid-header .k-header .k-link {
        height: auto;
    }

    .k-grid .k-grid-header .k-header {
        white-space: normal;
    }

    .vendor-controls {
        cursor: pointer;
        margin: 0 auto;
        width: 20px;
        height: 1.2em;
        max-height: 1.2em;
        padding: 6px;
    }
</style>
<div style="display:none">
    <ul id="vendor-search-grid-context-menu">
        <li id="copyText">@Html.Raw("Copy Text".Translate())</li>
    </ul>
</div>
@{
    var excludedFieldSet = ViewBag.ExcludedFields as HashSet<string> ?? Enumerable.Empty<string>();
    var choosenColumns = ViewBag.ChoosenColumns as HashSet<string> ?? Enumerable.Empty<string>();
    var availableStatus = (System.Collections.IEnumerable)ViewBag.AvailableStatus;
    var moduleName = ViewBag.ModuleName;
    var registrationType = (System.Collections.IEnumerable)ViewBag.RegistrationType;

    int defaultGridSize = int.TryParse(ViewData["DefaultGridSize"]?.ToString(), out int gridSize) ? gridSize : 20;
    var partialViewPath = "~/Areas/Registration/Views/PartialViews/VenderProfilesAction.cshtml";

    var multipleEditWindowErrorMessage = "Cannot save vendor data with multiple windows open. Please edit one vendor at a time".Translate();
}
<div class="k-grouping-header" style="padding-top: 10px; border-color: var(--button-border-color); border-width: 1px; border-style: solid; border-radius: 3px;width: calc(100% - 50px)">
    @await Html.PartialAsync(partialViewPath)
</div>
@(Html.DataGrid<VendorSearchResult>(false)
    .Name("vendorProfileGrid")
    .HtmlAttributes(new { @style = "height: 500px;width: calc(100% - 50px)" })
    .Reorderable(r => r.Columns(true))
    .Selectable(selectable => selectable
        .Mode(GridSelectionMode.Multiple)
        .Type(GridSelectionType.Row))
    .Resizable(r => r.Columns(true))
    .Pageable(p =>
    {
        p.Refresh(true);
        p.PageSizes([25, 50, 75, 100, 1000, 5000, 10000]);
    })
    .Events(_ => { })
    .Columns(columns =>
    {
        columns.Bound(v => v.VR_Id).Title("VR ID".Translate()).ClientTemplate("#= VR_Id === 0 ? '' : VR_Id #").Width(180).Lockable(false).Locked(true).Filterable(f => f.Cell(cell => cell.Template("VendorProfile.decimalToIntFilter"))).Visible(vendorProfileHelper.IsVrIdDisplayInGrid && choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.VR_Id), StringComparison.OrdinalIgnoreCase))).HeaderHtmlAttributes(new { @class = "NumericHeaderAlign" }).HtmlAttributes(new { @class = "NumericRowAlign" });
        columns.Bound(v => v.VendorId).Title("Vendor Number".Translate()).ClientTemplate("#= VR_Id === 0 ? '' : (VendorId || '') #").Lockable(false).Locked(true).Width(150).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.VendorId), StringComparison.OrdinalIgnoreCase))).HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.CompanyName).Title("Company Name".Translate()).Width(220).Lockable(false).Locked(true).ClientTemplate("#=  VR_Id === 0 ? CompanyName : VendorProfile.buildCompanyNameLink(CompanyName, '" + @Url.Action("GetCompanyUrl") + "')#").Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.CompanyName), StringComparison.OrdinalIgnoreCase))).HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.CompanyNameDBA).Title("Company Name DBA".Translate()).Width(220).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.CompanyNameDBA), StringComparison.OrdinalIgnoreCase))).HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.VendorControls).Title("Vendor Controls".Translate()).Width(140)
            .ClientTemplate("#=  VendorControls ? '<div onclick=\"VendorProfile.openValidationResultDialogWindow(this)\"><span class=\"fal fa-check-circle validation-pass-icon-grid\"></span></div>':'<div onclick=\"VendorProfile.openValidationResultDialogWindow(this)\"><span class=\"fal fa-times-circle validation-fail-icon-grid\"></span></div>'  #")
            .Filterable(filterable => filterable.Messages(m => m.IsFalse("Fail".Translate()))
                .Messages(m => m.IsTrue("Pass".Translate()))).Visible((ViewBag.IsDisplayVendorControlInGrid ?? true) && choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.VendorControls), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "IconHeaderAlign" })
            .HtmlAttributes(new { @class = "IconRowAlign" });
        columns.ForeignKey(v => v.Status, availableStatus, "Value", "Name")
            .Title("Status".Translate())
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" })
            .ClientTemplate("#= VR_Id === 0 ? 'DISCOVERY' : VendorProfile.getGridTextByValue(Status,'Status') #")
            .Width(180)
            .Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.Status), StringComparison.OrdinalIgnoreCase)))
            .HtmlAttributes(new { @data_displayToolTip = "True", @data_column_name = nameof(VendorSearchResult.Status), @class = "StringRowAlign" });
        columns.Bound(x => x.Status_Desc).Title("Status".Translate()).ClientTemplate("#= VR_Id === 0 ? 'DISCOVERY' : Status_Desc #").Hidden(true).IncludeInMenu(false).HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(x => x.RegistrationType_Desc).ClientTemplate("#= RegistrationType_Desc == null ? '' : RegistrationType_Desc.toUpperCase() #").Title("Registration Type".Translate()).Hidden(true).IncludeInMenu(false);
        columns.ForeignKey(v => v.SubStatus, availableStatus, "Value", "Name").ClientTemplate("#= SubStatus == null ? '' : VendorProfile.getGridTextByValue(SubStatus,'SubStatus') #").Title("Sub Status".Translate()).Width(140).Visible((ViewBag.IsDisplaySubStatusColumnInGrid ?? false) && choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.SubStatus), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.ForeignKey(v => v.RegistrationType, registrationType, "Value", "Name").ClientTemplate("#= RegistrationType == null ? '' : VendorProfile.getGridTextByValue(RegistrationType,'RegistrationType').toLocaleUpperCase() #").Title("Registration Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.RegistrationType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.SupplierType).Title("Supplier Type".Translate()).Width(200).Visible( choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.SupplierType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.SupplierSubType).Title("Vendor Category".Translate()).Width(140).Visible( choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.SupplierSubType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.SupplierSubType).Title("Vendor Category".Translate()).Width(140).Visible( choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.SupplierSubType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.BusinessUnit).Title("Business Unit".Translate()).Width(140).Visible( choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.BusinessUnit), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.ProjectCode).Title("Project Code".Translate()).Width(140).Visible(sysSettingHelper.IsProjectCodeDrivenWorkflowEnabled && choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.ProjectCode), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.AddressTypeDescription).Title("Address Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.AddressTypeDescription), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.PayeeName).Title("Payee Name".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.PayeeName), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.PayeeDBA).Title("Payee DBA".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.PayeeDBA), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.InvitedBy).Title("Invited By".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.InvitedBy), StringComparison.OrdinalIgnoreCase)))
            .HtmlAttributes(new { @data_displayToolTip = vendorProfileHelper.IsUpdatedByToolTipToShowName, @data_column_name = nameof(VendorSearchResult.InvitedBy), @class = "StringRowAlign invited-by-tooltip" }).HeaderHtmlAttributes(new { @class = "StringHeaderAlign" });
        columns.Bound(v => v.CreatedDate).Format("{0:G}").Title("Date Registered".Translate()).Width(180).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.CreatedDate), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "DateHeaderAlign" }).HtmlAttributes(new { @class = "DateRowAlign" });
        columns.Bound(v => v.UpdatedBy).Title("Updated By".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.UpdatedBy), StringComparison.OrdinalIgnoreCase)))
            .HtmlAttributes(new { @data_displayToolTip = vendorProfileHelper.IsUpdatedByToolTipToShowName, @data_column_name = nameof(VendorSearchResult.UpdatedBy), @class = "StringRowAlign" })
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" });
        columns.Bound(v => v.UpdatedDate).Format("{0:G}").Title("Last Update".Translate()).Width(180).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.UpdatedDate), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "DateHeaderAlign" }).HtmlAttributes(new { @class = "DateRowAlign" });
        columns.Bound(v => v.ProfileType).Title("Profile Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.ProfileType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.IndividualType).Title("Individual Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.IndividualType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.GlobalSmartVMNumber).Title("Global SmartVM Number".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.GlobalSmartVMNumber), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.ParentSmartVMNumber).Title("Parent SmartVM Number".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.ParentSmartVMNumber), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.SmartVMBusinessEntityType).Title("SmartVM Business Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.SmartVMBusinessEntityType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.SmartVMBusinessEntitySubType).Title("SmartVM Business Subtype".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.SmartVMBusinessEntitySubType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.BusinessEntityType).Title("Business Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.BusinessEntityType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.TaxClassification).Title("Tax Classification".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.TaxClassification), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.IncomeType).Title("Income Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.IncomeType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.BusinessOwnershipType).Title("Business Ownership Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.BusinessOwnershipType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.VendorRequestType).Title("Vendor Request Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.VendorRequestType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.LocalLanguageCompanyCountry).Title("Local Language Company Country".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.LocalLanguageCompanyCountry), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.LocalLanguageCompanyName).Title("Local Language Company Name".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.LocalLanguageCompanyName), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.LocalLanguageCompanyNameDBA).Title("Local Language Company NameDBA".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.LocalLanguageCompanyNameDBA), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.AddressInfo).Title("Address Info".Translate()).Width(240).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.AddressInfo), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.BankName).Title("Bank Name".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.BankName), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.BankAddress).Title("Bank Address".Translate()).Width(240).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.BankAddress), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.PersonName).Title("Person Name".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.PersonName), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.ContactType).Title("Contact Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.ContactType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.Email).Title("Email".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.Email), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.PhoneInfo).Title("Phone Info".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.PhoneInfo), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.TaxType).Title("Tax Type".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.TaxType), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Bound(v => v.TaxIdNumber).Title("Tax Id Number".Translate()).Width(140).Visible(choosenColumns.Any(x => string.Equals(x, nameof(VendorSearchResult.TaxIdNumber), StringComparison.OrdinalIgnoreCase)))
            .HeaderHtmlAttributes(new { @class = "StringHeaderAlign" }).HtmlAttributes(new { @class = "StringRowAlign" });
        columns.Command(command => { command.Custom("Delete").Visible("VendorProfile.deleteVendorProfileRowVisible").Text("Delete".Translate()).Click("VendorProfile.deleteVendorProfile"); }).Width(200).Visible((ViewBag.IsDisplayDeleteColumnInGrid ?? false) && !excludedFieldSet.Contains(nameof(VendorSearchResult.IsDeleteAllowed)))
            .HeaderHtmlAttributes(new { @class = "IconHeaderAlign" }).HtmlAttributes(new { @class = "IconRowAlign" });
    })
    .Sortable()
    .Events(e => { e.DataBound("VendorProfile.vendorProfileGridDataBound").Change("VendorProfile.onVendorProfileGridChange").ExcelExport("VendorProfile.vendorProfileGridDataExcelExport"); })
    .AutoBind(true)
    .Editable(e => { e.Enabled(false); })
    .DataSource(datasource => datasource
        .Custom()
        .Type("aspnetmvc-ajax")
        .PageSize(defaultGridSize)
        .Transport(t => { t.Read(r => r.Url(Url.Action("ReadVendorProfiles", new { ModuleName = moduleName })).Data("VendorProfile.getVendorProfileAdditionalData")); }
        )
        .Schema(s => s
            .Model(model => { model.Id(request => request.VendorSearchResultId); })
            .Data("Data")
            .Total("Total")
        )       
        .ServerSorting(true) // as we are pulling 2000 records at a time from service, don't use server side sorting, paging, filtering
        .ServerPaging(true) // Once moved to odata service, we can turn it on
        .ServerFiltering(true)
        .ServerGrouping(false)
        .ServerAggregates(false)
        .Events(events => events.Error("VendorProfile.onGridError")
            .RequestEnd("VendorProfile.onGridRequestEnd")
            .RequestStart("VendorProfile.onGridRequestStart")
            .Change("VendorProfile.onVendorProfileGridChange"))
    )
)


<script>
    window.multipleEditWindowErrorMessage = '@multipleEditWindowErrorMessage';
</script>

this is my Layoutm Code

 

@using System.Threading
@using apexanalytix.app.HtmlHelperExtensions
@using apexanalytix.app.ViewComponents
@using apexportal.Services.Abstractions
@using Microsoft.AspNetCore.Mvc.Localization
@using Portal.BusinessObjects.Common
@model Portal.Models.MvcProfilePageModel
@inject SysSettings SysSettings
@inject IViewLocalizer Localizer

<!DOCTYPE html>
<html lang="@Thread.CurrentThread.CurrentUICulture.TwoLetterISOLanguageName">
<head id="Head1">
    <meta http-equiv="X-UA-Compatible" content="IE=EDGE" charset="utf-8"/>
    <style>
        body {
            min-width: 850px;
            width: 100%;
        }

        .field-validation-valid {
            padding: 0 !important;
            margin: 0 !important;
            display: none !important;
        }

        /* Int, Long, Percentage */
        .NumericHeaderAlign {
            text-align: center !important;
        }

        /* Int, Long, Percentage */
        .NumericRowAlign {
            text-align: right;
        }

        /* Date and Date + Time */
        .DateHeaderAlign {
            text-align: center !important;
        }

        /* Date and Date + Time */
        .DateRowAlign {
            text-align: center;
        }

        /* Alpha Numeric */
        .StringHeaderAlign {
            text-align: left !important;
        }

        /* Alpha Numeric */
        .StringRowAlign {
            text-align: left;
        }

        /* Images, Icons */
        .IconHeaderAlign {
            text-align: center !important;
            text-overflow: clip !important;
        }

        /* Images, Icons */
        .IconRowAlign {
            text-align: center !important;
            text-overflow: clip !important;
        }
    </style>

    <link href="/Content/Themes/uilightness/jqueryui" rel="stylesheet" type="text/css"/>
    <link href="/Content/VendorRegistrationMaster" rel="stylesheet" type="text/css"/>

    <script src="/Styles/fa-pro-5_15_1/js/all.min.js"></script>
    @{
        var englishPageTitle = SysSettings.SiteContent[ValueName.PageTitleBase];
        var pageTitle = Localizer[englishPageTitle.Value ?? string.Empty].Value + " - " + ViewBag.Title;
    }

    <title id="Title1">@pageTitle</title>
</head>

<body style="width: 100%">

<!-- menu popup-->

<div class="modelbg" style="display: none;"></div>
<div id="cloneMenu" style="display: none;">
    <div id="cloneContent"></div>
</div>
<div id="fadeSection">
    <div id="coreDialog" style="display: none">
    </div>
</div>
<input type="hidden" id="hdnThemeMode"/>
@{
    var enableAutoComplete  = SysSettings.Display[ValueName.EnableBrowserAuto_complete].GetValue<bool>();
    var cultureCode = HtmlExtensions.GetFullCultureCode();
}
<form id="Form1" autocomplete="@(enableAutoComplete ? "on" : "off")">
    <script src="/bundles/MsAjaxJs"></script>
    <script src="/bundles/jquery"></script>
    <script src="/bundles/jqueryui"></script>
    <script src="/Scripts/kendo/2024.3.1015/kendo"></script>
    <script src="/bundles/WebFormsJs"></script>

    <script src="/bundles/PortalMaster"></script>
    <script src="/bundles/jqueryval"></script>
    <script src="/bundles/KendoWindowManager"></script>

    <script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/1.7.1/clipboard.min.js"
            type="text/javascript"></script>
    <script src="/Scripts/kendo/2024.3.1015/messages/kendo"></script>
    <script src="/Scripts/kendo/2024.3.1015/cultures/kendo"></script>
    <script src="~/Scripts/kendo/2024.3.1015/cultures/kendo.culture.@(cultureCode).min.js" type="text/javascript"></script>
    <script src="~/Scripts/kendo/2024.3.1015/messages/kendo.messages.@(cultureCode).min.js" type="text/javascript"></script>
    <script>
        kendo.culture("@(cultureCode)");
    </script>


    <div id="body">

        @{ await Html.RenderPartialAsync("~/Views/Shared/_Header.cshtml", ViewData); }
        @{ await Html.RenderPartialAsync("~/Views/Shared/_ThemeMode.cshtml", ViewData); }
        @{ await Html.RenderPartialAsync("~/Views/Shared/_GridRowDeleteDialog.cshtml", null); }
        @{ await Html.RenderPartialAsync("~/Views/Shared/_popupDialog.cshtml", null); }

        <div class="container-fluid landing-container">
            <div class="sidebar border-right bg-body-tertiary">
                <div class="sideMenubtm">
                    @{
                        await Html.RenderPartialAsync("~/Views/Shared/_MainMenu.cshtml", ViewData);
                    }
                </div>

            </div>
            <div class="main-content-section">
                <div id="bodytitle">
                    @{ await Html.RenderPartialAsync("~/Views/Shared/_Breadcrumb.cshtml", ViewData); }
                </div>
                <div id="bodynews">
                    @if (false)
                    {
                        await Component.RenderActionAsync("GetWelcomeBanner", "Dashboard");
                    }
                </div>
                <div style="padding: 0 24px; margin-bottom: 100px">
                    @RenderBody()
                    @await Component.ExtendKendoValidationsAsync()
                    <script type="text/javascript">
                        $(document).ajaxError(function (xhr, props) {
                            if (props.status === 401) {
                                location.reload();
                            }
                        });
                    </script>
                </div>
                @if (ViewBag.StartSessionExpire != false)
                {
                    await Html.RenderPartialAsync("~/Views/Shared/_SessionExpireNotification.cshtml", ViewData);
                }
            </div>
        </div>
        @{
            if (SysSettings.HomePage[ValueName.DisplayFooter].GetValue<bool>() && !(Model?.HideFooter ?? false))
            {
                <partial name="~/Views/Shared/_Footer.cshtml"/>
            }
        }
    </div>

</form>

<script type="text/javascript">

    var commonBaseUrl = '@Url.Content("~/")';

    function Translate(error) {
        try {

            let url = '/Registration/Common/TranslateJSStrings';
            $.ajax({
                type: "POST",
                async: false,
                url: url,
                contentType: "application/json; charset=utf-8",
                data: JSON.stringify({
                    Message: error
                }),
                success: function (result) {
                    error = result.d;
                }
            });

            return error;

        } catch (ex) {
        }
    }

</script>

@Html.RenderUnobtrusiveAjaxScript()

@await Component.GoogleAnalyticsAsync(SysSettings.SiteConfiguration[ValueName.AnalyticsId].GetValue<string>(), Context.User.Identity?.GetUserId())

</body>
</html>

 

 

this is my Error.

 

 

 

 

Ivaylo
Telerik team
 answered on 29 Jul 2025
0 answers
28 views

Good morning,
i am using MVC.ASP net in my project and i'm trying to send the DataSourceRequest to a service , via rabbitmq.

the message should contains all the request filters set in the ui in order to create an excel report. i have tried to use the System.Text.Json serialization but it's not working properly. it serializes only the first level props.
i have found a ".ToJson" extension  but it's returning a Dictionary<string, object>, not usefule here.

can you suggest how to serialize the DataSourceRequest in Json format? with all nested and recursive properties?

the filters can be about dates, strings, combobox, and so on

thanks in advance

1 answer
32 views
good morning,
i am facing a strange behavour with the datetime filter in grid.
when i set a date on the second filter about the "Is before" and none in the "Is after on", launch the grid data and re-open the date filter, values are inverted, see attachments "before" and "after".
can you tell me how to block the filter positions? "is after on" set always as first and "Is before" alwasy set as second.

thanks in advance
Mihaela
Telerik team
 answered on 16 Jul 2025
10 answers
2.1K+ views

Hi Guys

This stupid little issue is taking up way way too much time for me to resolve..

I am setting a timepicker as follows:

  <td class="tg-7uzy">

                @Code
                    With Html.Kendo().TimePicker()
                        .Name("1Open")
                        .Events(Function(events) events.Change("settime"))
                        .Value(New TimeSpan(0, Model.Hours(1).open, 0))
                        .Min(New TimeSpan(0, 0, 0))
                        .Max(New TimeSpan(0, 0, 0))
                        .Render()
                    End With
                End Code
            </td>

The result is as per the attached screen shot.

It 'looks like' the values are set right as the timepickers have the correct times , but when you drop down, it always starts at midnight and the current time is not highlighted.  I assume the timepicker needs the value to be set with AM or PM .. but that can't be done from a TimeSpan or a datetime.. the am pm always has dots ( a.m.  , p.m.)

 

If tried adding .Format("HH:mm:tt") and  .ParseFormats(New String() {"HH:mm:tt"}) etc, but I just can't get it to work. ( I've tried allot more formats than just these, I've tried "HH:mm tt" ,"HH:mm t.t." ( cause it's the dots around the am pm which seems to be whats stopping.))

Feeling a bit stupid having to ask this as it seems to be a straightforward thing.

I'm sure I will have a Face palm moment when shown the error in my ways.. but I've got to the point of not caring! :)

Cheers

Rob

 

Lorenzo
Top achievements
Rank 1
Iron
 answered on 30 Jun 2025
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
Upload
ComboBox
MultiSelect
ListView
Window
TabStrip
Menu
Installer and VS Extensions
Spreadsheet
AutoComplete
TreeList
Gantt
PanelBar
NumericTextBox
Filter
ToolTip
Map
Diagram
Button
PivotGrid
Form
ListBox
Splitter
Application
FileManager
Sortable
Calendar
View
MaskedTextBox
PDFViewer
TextBox
Toolbar
MultiColumnComboBox
Dialog
DropDownTree
Checkbox
Slider
Switch
Notification
ListView (Mobile)
Pager
Accessibility
ColorPicker
DateRangePicker
Wizard
Security
Styling
Chat
MediaPlayer
TileLayout
DateInput
Drawer
SplitView
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Template
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Rating
ScrollView
ButtonGroup
CheckBoxGroup
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Licensing
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
DropDownButton
AIPrompt
PropertyGrid
ActionSheet (Mobile)
BulletGraph
Button (Mobile)
Collapsible
Loader
CircularGauge
SkeletonContainer
Popover
HeatMap
Avatar
ColorGradient
CircularProgressBar
SplitButton
StackLayout
TimeDurationPicker
Chip
ChipList
DockManager
ToggleButton
Sankey
OTPInput
ChartWizard
SpeechToTextButton
InlineAIPrompt
TimePicker
StockChart
RadialGauge
ContextMenu
ArcGauge
AICodingAssistant
+? more
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Ambisoft
Top achievements
Rank 2
Iron
Pascal
Top achievements
Rank 2
Iron
Matthew
Top achievements
Rank 1
Sergii
Top achievements
Rank 1
Iron
Iron
Andrey
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?