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

Hi there,

In my grids, I have a column with a menu :

columns.Template(@<text></text>).Width(106).HtmlAttributes(new { @class = "templateCell" }).ClientTemplate(
                    Html.Kendo().Menu().Direction(MenuDirection.Left)
                        .Name("menu_#=AccountId#")
                        .Items(its =>
                        {
                            its.Add().Text("Functions:").Items(nested =>
                            {
                                nested.Add().Text(importFilesText).Action(importFilesAction, "Accounts", new { id = "#=AccountId#", cid = Model.CompanyId, returnUrl = returnUrl});
                            });

                        })
                        .ToClientTemplate().ToHtmlString()
                    );
                })

 

But in the TreeList there is no ClientTemplate

 

I tried using the TemplateId

<script id="menuFolder" type="text/x-kendo-template">
            @(Html.Kendo().Menu()
                  .Name("menu")
                  .Direction(MenuDirection.Left)
                  .Items(its =>
                  {
                      its.Add().Text("Functions:").Items(nested =>
                      {
                          nested.Add().Text("Create Rule").Url("javascript:createRule(#=Id#, #=AccountId#, #=CompanyId#);");
                          nested.Add().Separator(true);
                          nested.Add().Text("Select Account QBEAccountId").Url("javascript:SelectId(#=Id#);");
                      });
                  })
                  .ToClientTemplate())
</script>

And I can get the menu to display, but it is cut of inside the treelist.

In the old days with the grid we used to change the css of the parent with overflow-y:display !important; but that does not seem to work.

Any ways this can be accomplished in the treelist - next step is the items in the list are depending on the content of the row ...

 

Best regards,

 - RenĂ©

Eyup
Telerik team
 answered on 17 Jun 2025
3 answers
736 views

I have a simple multiselect like so:

@(Html.Kendo().MultiSelectFor(x => x.CourseId)
      .DataValueField("Id")
      .DataTextField("Name")
       .Placeholder("Select Course...")
      .ClearButton(false)
      .DataSource(source =>
      {
          source.Read(read =>
          {
              read.Action("GetCourseCodeList", "Home");
          })
          .ServerFiltering(true);
      })
      .MaxSelectedItems(1)
      .HtmlAttributes(new { @class = "" }))

When I enter text, the search is submitted once with the text entered, then a second time with the Placeholder text, or if no Placeholder, with empty string.

public JsonResult GetCourseCodeList(string text, int categoryId=0)
{
    var items = _courseData.Where(x =>
        x.Name.Contains(text) &&
        (categoryId == 0 || x.CategoryId == categoryId)).OrderBy(x => x.Name).ToList();
 
    var userinput = text;
 
    var result = new JsonResult
    {
        JsonRequestBehavior = JsonRequestBehavior.AllowGet,
        Data = items
    };
    return result;
}

A sample project replicating the issue is here : https://github.com/SteveWortho/TLCKendoTest 

It must be something simple I am doing wrong - any advice appreciated.

Using;

VS2017 Pro Version 15.5.1

KendoUI MVC 2017.3.1026

Chrome Version 63.0.3239.132 or Microsoft Edge or FireFox. Issue is repeatable.

So I must be firing the onChange event a second time with some of this configuration maybe?

But it is such a simple example.

Thanks in advance,

Steve

 

 

 

Rick
Top achievements
Rank 1
Iron
 answered on 10 Jun 2025
1 answer
72 views

Hi,

I have a Kendo Grid and its first column is a Datetime and Its a Kendo DatePicker.

When the user click on Add new record button then the 1st cell which is a date picker should be auto focus.

Note: When the user click on Add new record button then we are sorting the grid in ascending order so that the new row should appear on the top, which is working fine but the 1st cell of the newly created row a Kendo Date picker in not in focus.

 

But when the user click on the first cell of the newly created row, then it opens the datepicker to allow user to select a date.

 

My requirement is when i am clicking the Add new record button then 
1. It should sort in ascending order (Which is working now)

2. The 1st cell of the Kendo Datepicker should auto focus like the above screenshot.


 
abdul
Top achievements
Rank 2
Iron
Iron
 updated question on 09 Jun 2025
1 answer
136 views

Hi,

I have a requirement in the Kendo grid

1. When the user click on cross icon in each row in the action column then the row should be deleted.

2. In the last available row, a + icon should display and when the user clicks the + icon then it should create new row in the grid 

instead of normal Add new record button.

 

 

 

 

 

abdul
Top achievements
Rank 2
Iron
Iron
 updated question on 09 Jun 2025
1 answer
81 views

Hi,

I want to load a kendo grid, after load the grid should add a new row at the bottom of the grid.

 

When the Kendo grid loads then, it is creating the new row, but after that it will load the records from the database and then refresh the screen and the new row is removing.

abdul
Top achievements
Rank 2
Iron
Iron
 updated question on 09 Jun 2025
1 answer
41 views

Hi,

I have a kendo grid, where i am creating a new empty row while loading the grid.

The grid has a Boolean filed which is a mandatory field. so when we want to enter the row values then it should call the CheckIsPublicFund(data) method and if the user is not selecting the Boolean field then it should add that value to false.

The problem is when selecting the Boolean value then its not firing the CheckIsPublicFund(data)  method.

 


 


abdul
Top achievements
Rank 2
Iron
Iron
 updated question on 09 Jun 2025
1 answer
46 views

Hi,

I am working on a kendo grid, where user can copy records from the excel and paste in the kendo grid.

But when we copy more than 50 records from the excel and paste in the kendo grid then it is taking some time.

Can we increase the performance while pasting in to the Kendo grid or is it possible we can provide a progress bar or something to show to the user when the user paste more than 50 record.

 

abdul
Top achievements
Rank 2
Iron
Iron
 updated question on 09 Jun 2025
2 answers
42 views
Hi,

I'm using Kendo UI for ASP.NET MVC and I need to add an HTML link (<a href="...">) inside the CategoryAxis.Labels.Template or the ValueAxis.Labels.Template of a Bar Chart. Here is a simplified version of my code:

@(Html.Kendo().Chart()
    .Name("productsChart")
    .Series(series =>
    {
        series.Bar(new[] { 100, 200, 300 }).Name("Sales");
    })
    .CategoryAxis(axis => axis
        .Categories("Product A", "Product B", "Product C")
        .Labels(labels => labels
            .Template("<a href='https://example.com/product/#= value #' target='_blank'>#= value #</a>")
        )
    )
)


However, the chart only displays the raw text of the <a> tag instead of rendering it as a clickable HTML link. I understand this may be due to the chart rendering via SVG and not supporting HTML natively in axis labels.

Is there any workaround or supported way to:

Render actual HTML in axis labels?

Enable links or interactive elements within axis labels?

I’ve already considered using tooltips and seriesClick events as alternatives, but my goal is to have direct clickable links inside the axis labels themselves.

Thanks for your help!
Eyup
Telerik team
 answered on 03 Jun 2025
1 answer
61 views

Hello,

I created new project using Telerik wizard. I am trying to populate a grid with data-source using ajax but I am failing at using ToDataSourceResult. I am getting error 

'IEnumerable<Person>' does not contain a definition for 'ToDataSourceResult' and the best extension method overload 'QueryableExtensions.ToDataSourceResult(DataTable, DataSourceRequest)' requires a receiver of type 'System.Data.DataTable'

I compared it with project created by Telerik wizard for page with grid and still don't see why this error occurs.

Please see attached figure. It is screenshot taken from HomeController where I am trying to get data-source from IEnumerable. 

Radek
Top achievements
Rank 2
Iron
 answered on 03 Jun 2025
1 answer
42 views

Hi,

I'm trying to figure out how to transpose columns in a Kendo Grid using the Html helper. 

I see that there's this small piece of documentation for jQuery (https://docs.telerik.com/kendo-ui/knowledge-base/transposed-grid), but would ideally like to do it on the helper itself.

Is anyone aware of how to do this? 

Any help is much appreciated!

Mihaela
Telerik team
 answered on 23 May 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?