Declined
Last Updated: 25 Mar 2024 13:37 by ADMIN
Server filtering kendo grids and json deserialization errors in asp.net.
When we are managing large volumes of data with several thousand datasource objects (grid rows) all of the rows need to be transported with each event.
This leads to errors with the json being too large to serialize.

We wish to restrict the data footprint and only return data for the page requested.
so if the grid has 100 pages and page size is 10 we only want to return the 10 rows required for the page, not 1000 rows.
This is not possible with the Kendo grid.
To work around this issue we have devised a strategy to return the the number of datasource objects Kendo grid expects up to the requested page count, but they are empty objects with no data, and then only have the last 10 rows populated with data.
It would be better for the grid control just to expect the number of results expected to the selected page and not have to add the dummy rows, so long as the total number of rows is provided so that the grid knows how many pages there are.

Our work around looks something like this in asp.net MVC

var users = cm.getUsers();
var result = new DataSourceResult();
var results = new List<user>();
int index = 0;
if (pageNum == 1)
    results = users.Take(pageSize).ToList();
else
{
     index = pageSize * (pageNum - 1);
     results = users.Skip(index).Take(pageSize).ToList();
}
List<user> output = null;

[This is the bit that should be handled by the kendo grid, without the need for dummy rows to further reduce json size]
if (index == 0)
{
     output = new List<user>(results);
}
else
{
     output = new user[index].ToList();
     output.AddRange(results);
}
result = output.ToDataSourceResult(request);
result.Total = users.Count();
return Json(result, JsonRequestBehavior.AllowGet);
Declined
Last Updated: 25 Mar 2024 13:31 by ADMIN
Created by: Chris
Comments: 1
Category: UI for ASP.NET MVC
Type: Bug Report
0

I have a cshtml page that uses Kendo UI ASP.NET MVC that does the following:

  • sends an ajax request to a controller action method,
  • opens a new tab using window.open(),
  • displays a temporary message to let the user know that something is happening,
  • then overwrite the new tab content using the view that is contained in the ajax response.

The view contains one or more grid widgets (the number depends on how many result types were requested) and each grid is set up to export Excel.

The problem is that when window.open() is used to open a new tab, the browser history state is null and the window.location.href is empty with the browser location showing "about:blank". For Chrome and Firefox, this does not cause any issues when exporting excel for the grid.  However, when using Edge with this situation, when the Export to Excel grid toolbar button is clicked and the onExportExcel event is fired,  the browser Open or Save dialog prompt is displayed but the active tab (the one that contained the grid) closes. This behaviour is very undesireable. The ProxyUrl grid excel option does not fire since Edge supports javascript file saving.

A workaround for this situation is to forcibly set the new tab window object location href by using the window.history.pushUpdate function. A code snippet is included below.


let dataModel = {Id = 123571113, Name="jason bourne"};
let jsonModel = JSON.stringify(dataModel);
let curDate = new Date();
let targetUrl = '@Url.Action("Reports", "Report", new { @area = "Reports" })';
let targetWindowName = "something meaningful" + " " + curDate.toISOString();//add datetime stamp to avoid issue where you cannot open a window with the same name as the current window.
let html = "some html content to provide a temporary message to your audience";
let targetWindow = window.open(targetUrl, targetWindowName);
if (targetWindow !== null && targetWindow !== undefined)
{
   targetWindow.document.write(html);
   targetWindow.document.close(); // to finish loading the page
   targetWindow.document.title = targetWindowName;

   //attempt to forcibly update the URL in the history and target window location to fix problem with grid export to excel on Edge browser
   let targetWindowHistoryHref = window.location.href;
   if (oModel.BuildingDesigns !== null && oModel.BuildingDesigns !== undefined && oModel.BuildingDesigns.length > 0) {
       targetWindowHistoryHref += "?oBuildingDesignId=" + oModel.BuildingDesigns[0].ObfuscatedBuildingDesignId + "&BuildingDesignName=" + oModel.BuildingDesigns[0].BuildingDesignName;
   } else {
       targetWindowHistoryHref += "?" + oModel.Target;
   }
   targetWindow.history.pushState(null, null, targetWindowHistoryHref);
}
$.when(
	$.ajax({
		type: "POST",
		dataType: "html", // this is the data type expected to be returned from the controller method
		contentType: "application/json", // this is the content type expected by the controller method
		url: targetUrl,
		data: jsonModel,
		beforeSend: function() {
			console.log(".... submitting report request");
			athena.loader.loading("submitting report request");
		},
		success: function(response) {
			athena.loader.stopLoading();
			if (debugLevel > 2) {
				console.log(".... response = " + response + " : ", response);
			}

			//attempt to populate the target browser tab with the response
			try {
				console.log(".... attempting to open a browser tab and populate it with the HTML response object");
				console.log(".... targetWindow = " + targetWindow);
				//will trigger popup blockers :: targetWindow = window.open("", oModel.Target);
				if (targetWindow !== null) {
					if (response === null || response === undefined) {
						targetWindow.document.body.innerHTML = '';
					} else {
						//completely replace the existing document (not just the innerhtml)
						targetWindow.document.open();
						targetWindow.document.write(response);
						targetWindow.document.close();
						targetWindow.document.title = targetWindowName;
					}
				}
			} catch (ex) {
				// do nothing, just catch when the open fails.
				console.log("error: " + ex.message);
			}
		},
		error: function(jqXhr, textStatus, errorThrown) {
			console.log('.... error :: ajax status = ' + textStatus + ' :: errorThrown = ' + errorThrown);
			console.log('....-- jqXhr.responseText :: \n' + jqXhr.responseText);
		}
	})
).done(
	function() {
		console.log(".... report request has completed");
		targetWindow.focus();
	}
);

Declined
Last Updated: 27 Jun 2023 08:26 by ADMIN

Test Environment:

OS Version: 22H2 OS Build 22621.1702

Edge Version: Edge(Chromium) Version 114.0.1823.37 (Official build) (64-bit)

 

Repro-Steps:

  1. Open  ASP.NET MVC Grid Web API Binding Demo | Telerik UI for ASP.NET MVC with valid credentials in Edge browser.
  2. Navigate through the page using Tab key till filter buttons.
  3. Run Tab stops and observe the issue whether focus is moving to the filter buttons or not.

Actual Result:
While navigating through the page, the Tab focus is not moving to the filter buttons.

Expected Result:
While navigating through the page, the Tab focus should move to the filter buttons.

User Impact:
Users with motor impairment and who rely on keyboard will face difficulties if the tab focus is not moving to the filter buttons.
Declined
Last Updated: 27 Jun 2023 08:26 by ADMIN

Test Environment:

OS Version: 22H2 OS Build 22621.1702

Edge Version: Edge(Chromium) Version 114.0.1823.37 (Official build) (64-bit)

 

Repro-Steps:

  1. Open Demo for core features in ASP.NET MVC Grid control | Telerik UI for ASP.NET MVC with valid credentials in Edge browser.
  2. Navigate through the page using Tab key till Expand/collapse button.
  3. Run Tab stops and observe the issue whether focus is not moving to the "expand/collapse" button. 

Actual Result:
While navigating through the page, the Tab focus is not moving to the expand and collapse button.

Expected Result:
While navigating through the page, the Tab focus should move to the expand and collapse button.

User Impact:
Users with motor impairment and who rely on keyboard will face difficulties if the tab focus is not moving to the expand and collapse button.
Declined
Last Updated: 22 Mar 2023 16:01 by ADMIN

Aren't the files in the /Content/kendo/2023.1.314/ folder KendoUI version files, not MVC version files?

Below is the contents of the file after upgrading to the new version.

I thought it was strange, so I browsed the stylesheet folder of the newly installed version.

The folder contents of the previous version were as follows.

Isn't it a problem with the distributed installation files?

 

Declined
Last Updated: 15 Feb 2022 15:59 by ADMIN
Created by: John
Comments: 6
Category: UI for ASP.NET MVC
Type: Bug Report
0

With the latest 2022 release, the grid toolbar seems to be rendering buttons incorrectly.  It is generating them with k-button and k-button-icontext classes only on them.  I don't 100% know this is wrong, but i expected them to render with k-button-solid-base and k-rounded-md classes, and i'm pretty sure i saw docs saying the icontext is not used anymore.

 

Note:  this is about the mvc wrapper.

 

Declined
Last Updated: 04 Feb 2022 08:46 by ADMIN

I'm not sure if this is a bug but if you leave the size off of a column, it stretches to fill the remaining area.  However I discovered that this does NOT happen if you lock one of your columns.  If you do this, the column doesn't render at all.

 

Declined
Last Updated: 15 Oct 2021 16:34 by ADMIN
Pretty easy to reproduce.  Have a standard comment in javascript in a custom grid popup editor like this:

<script> 
    //my amazing function|
function() {
  var x = 0;
  doSomething();
}


Your grid will "minify" this into a single line when including the popup code as an editor template.  This will break everything because javascript will treat everything after the double-slashes as a comment, which means the entire popup is now gone.

This has been an ongoing issue for years and we expected that your code would someday be smart enough to strip comments when minifying the popup (which minifying is supposed to do anyway) or perhaps convert them so they open and close.  

Note:  I realize it's not really a "minify" since it keeps the same variables but it's about as well as i can describe what's going on.

The requested solution is simply to strip comments out when pulling in the custom popup editor, as they are pretty much useless when the entire popup is in a single line anyway.
Declined
Last Updated: 12 Aug 2021 07:48 by ADMIN
Created by: Ken
Comments: 2
Category: UI for ASP.NET MVC
Type: Feature Request
3
Add the ability to display aggregates of non grouped columns in the group header.
Declined
Last Updated: 15 Jul 2021 07:25 by ADMIN
Created by: Imported User
Comments: 4
Category: UI for ASP.NET MVC
Type: Feature Request
1
Today, when we use IEnumerable<dynamic> type as the model for the kendo grid, the grid is generated fine, but the javascript serialization fails when we pass the datasource to the GridBuilder constructor.
This results in empty grid client side, because the datasource is empty, even if the html initially generated contains the values.

This behavior comes from a problem with the JavaScriptSerializer (also present in the JSon() function of MVC)
Declined
Last Updated: 15 Jul 2021 07:24 by ADMIN
If you change the dataSource to a grid (for example by changing the filter conditions) so that less data is returned, you will not be warned if the current page is no longer valid. No error is reported and no data is returned and you won't have a clue why.

Try this to replicate:

Make a paged grid plus a couple of datepickers to filter the grid data by date range. Add a button to make the new filter dates effective.

Write a new MVC controller method to populate the data, using the ToDataSourceResult extension method e.g. "return Json(obj.ToDataSourceResult(request));" to return data.

Open a sizeable dataset in the grid (many pages) and go to the last page.

Change the filter conditions to be much more restrictive. Click the button to make them effective.

Watch as the grid displays no data, the code reports no error and stepping into your controller confirms that the method is returning data.

Confusing huh? An error or warning would make this much clearer.
Declined
Last Updated: 15 Jul 2021 07:24 by ADMIN
Created by: viswesh
Comments: 2
Category: UI for ASP.NET MVC
Type: Feature Request
2
The existing solution was built in 2009 using .Net 3.5 web forms framework (List View), ASP.Net Ajax (Accordion) and JQuery (validation). 

The web page accomplishes the following key functional requirements –

a.	Ability to group products – The groups are dynamically extracted from the same datasource that is providing the product list.  Using ASP.Net Ajax we were able to provide the expand / collapse visual effect.

b.	Ability to enter order quantities very quickly -  a lot of stores place orders at the last minute  (5-10 minutes before order deadline) for valid reasons.  The web page readily provides a text box for quick entry.  On a desktop, the user can traverse the rows within the group using the tab key.   The web page typically contains 150 –  200 products for entry.  

Having to click on Edit/Update/Cancel dramatically increases the number of clicks / touch / swipe.  Besides, it creates a real estate issue on smaller form factors.  

c.	Real time validation – using JQuery we were able to validate the row as and when the quantity was entered.  Any error would show below the row in question.  The error would continue to show until the quantity was revised.  The error however, will not stop the user from entering quantities on other rows.  This approach lets the user review any errors in the end.
Declined
Last Updated: 15 Jul 2021 07:23 by ADMIN
Created by: Arne
Comments: 2
Category: UI for ASP.NET MVC
Type: Feature Request
1
Possibility to iterate over all manually defined columns and f.i. set width or any other property. 
Declined
Last Updated: 15 Jul 2021 07:22 by ADMIN
Static property requires null instance, non-static property requires non-null instance.
Parameter name: expression

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 

Exception Details: System.ArgumentException: Static property requires null instance, non-static property requires non-null instance.
Parameter name: expression

[ArgumentException: Static property requires null instance, non-static property requires non-null instance.
Parameter name: expression]
   System.Linq.Expressions.Expression.Property(Expression expression, PropertyInfo property) +4376691
   System.Linq.Expressions.Expression.MakeMemberAccess(Expression expression, MemberInfo member) +90
   Kendo.Mvc.Infrastructure.Implementation.Expressions.MemberAccessTokenExtensions.CreateMemberAccessExpression(IMemberAccessToken token, Expression instance) +122
   Kendo.Mvc.Infrastructure.Implementation.Expressions.ExpressionFactory.MakeMemberAccess(Expression instance, String memberName) +107
   Kendo.Mvc.Infrastructure.Implementation.Expressions.PropertyAccessExpressionBuilder.CreateMemberAccessExpression() +70
   Kendo.Mvc.Infrastructure.Implementation.Expressions.MemberAccessExpressionBuilderBase.CreateLambdaExpression() +17
   Kendo.Mvc.Infrastructure.Implementation.SortDescriptorCollectionExpressionBuilder.Sort() +120
   Kendo.Mvc.Extensions.QueryableExtensions.CreateDataSourceResult(IQueryable queryable, DataSourceRequest request, ModelStateDictionary modelState, Func`2 selector) +888
   Kendo.Mvc.Extensions.QueryableExtensions.ToDataSourceResult(IQueryable`1 enumerable, DataSourceRequest request, Func`2 selector) +58
Declined
Last Updated: 01 Jul 2021 12:12 by ADMIN
Created by: tim
Comments: 2
Category: UI for ASP.NET MVC
Type: Feature Request
4
ToDataSourceResult is very very slow on Large datasets - getting the Total Count is the issue, have an option to omit the total count or provide a way to inject the total count with some more efficient code.
Declined
Last Updated: 01 Jul 2021 11:33 by ADMIN
Created by: Imported User
Comments: 3
Category: UI for ASP.NET MVC
Type: Feature Request
1
We can add option for No filter in filter selection , Is consumes less space then other
Declined
Last Updated: 01 Jul 2021 11:17 by ADMIN
Created by: madcamp
Comments: 1
Category: UI for ASP.NET MVC
Type: Feature Request
1
today we need to loop through all rows in the Grid to do something in a row. On Telerik Extensions we had the OnRowDataBound event which we had the current row to do something. 
Declined
Last Updated: 01 Jul 2021 11:02 by ADMIN
Created by: Brian
Comments: 5
Category: UI for ASP.NET MVC
Type: Feature Request
2
Just getting started with Kendo Grid - below is my VB.NET razor code (I know, I know) working against a System.Data.DataTable for a model. 

The DataTable contains columns in it where some of the ColumnNames have spaces. The web page successfully renders my table, but, it errors due to the Kendo's row template, it seems.

    Dim mainGrid = Html.Kendo().Grid(Model.MainTable) _
         .Name("Grid") _
         .Columns(Sub(cols)
                          cols.AutoGenerate(True)
                  End Sub) _
         .DataSource(Sub(dSource)
                             dSource.Ajax()
                     End Sub) _
        .Pageable() _
        .Sortable() _
        .Filterable()
Declined
Last Updated: 01 Jul 2021 10:35 by ADMIN
Hi!
Created by: RahulD
Comments: 1
Category: UI for ASP.NET MVC
Type: Feature Request
1
Hi!
There should be something to post multiple grids data to controller. which was possible with serialize in telerik.
Declined
Last Updated: 30 Jun 2021 12:10 by ADMIN
Your HTML Helpers generate fairly simple HTML and javascript ... but its not easy to read because it is somewhat minified (at least it has no indentation). It would be nice to set a flag somewhere to enable a pretty print option. I assume you have something like that internally anyway?
1 2 3 4 5 6