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

I am beginning to dread new updates to Telerik UI for ASP.NET MVC. It takes hours and hours to upgrade.

For the last 2 upgrades I have had to unbind my ASP.NET MVC project from source control (TFS) before even attempting to run the upgrade wizard. If I am lucky it takes hours, if I am unlucky it takes hours and then runs out of memory.

Now I am trying to upgrade from v2017.3.913 to v2017.3.1018, I've unbound the project from source control, ran the upgrade wizard, eventually ran out of memory. I don't need all the culture files that the upgrade is trying to add to my project, which I presume is why the upgrade takes so long (and often fails).

I can't keep spending so much time trying to upgrade to the latest versions. So does anyone have any thoughts on how to speed this up?

 

Misho
Telerik team
 answered on 27 Oct 2017
5 answers
2.7K+ views

Hi,

i am generating a grid with Multi select Combo box in it using a column template.

i am able to select the multiselect combo values and able the read the selected items.

 

i have one more requirement, i have to select/check the values of multiselect combo values dynamically through JQuery.

Please help me how to do that? Below is the code.

This is the code of a grid, where i am creating Multiselect combo box in one of the cell.

var dataSource = new kendo.data.DataSource({

        transport: {
            read: function (e) {
                e.success(result);
            },
            update: function (e) {
                e.success();
            },
            create: function (e) {
                var item = e.result;
                item.Id = result.length + 1;
                e.success(item);
            }
        },
        schema: {
            model: {
                id: "SNO",
                fields: {
                    SNO: { type: "int" },
                    PassengerStatus: { type: "int" },
                    ElevatorShutdown: { type: "bool" },
                    TrappedPassenger: { type: "bool" },
                    UnitControllerStatus: { type: "bool" },
                    ActiveVoiceVideoCall: { type: "bool" },
                    controllerStatus: { type: "bool" },
                    Delay: { type: "int" }
                }
            }
        }
    });

    //my own
    $("#UnitgridPerf").kendoGrid({
        dataSource: dataSource,

        editable: { createAt: "bottom" },
        dataBound: function (e) {
            createMultiSelect(e);

        },
        // pageable: true,

        columns: [
            {
                field: "SNO", width: "50px", editable: function (arg) { return true; }, headerAttributes: {

                }
            },

            {
                field: "PassengerStatus", title: "PD", editable: function (arg) { return true; }, width: "40px"
                , headerAttributes: {

                }
            },
            {
                field: "ElevatorShutdown", title: "OOS", editable: function (arg) { return true; }, width: "50px"
                , headerAttributes: {

                }
            },
            {
                field: "TrappedPassenger", title: "TP", editable: function (arg) { return true; }, width: "50px"
                , headerAttributes: {

                }
            },
            {
                field: "UnitControllerStatus", title: "REM", width: "170px", editable: function (arg) { return false; }, template: "<select class='Multiselectval'></select>"
                , headerAttributes: {

                }


            },
            {

                field: "ActiveVoiceVideoCall", title: "VC", width: "50px", editable: function (arg) { return true; }
                    , headerAttributes: {

                    }

            },
            {
                field: "controllerStatus", title: "CTRL", width: "50px", editable: function (arg) { return true; }
                    , headerAttributes: {

                    }
            },

            {

                field: "Delay", editable: function (arg) { return true; }, width: "50px"
                , headerAttributes: {

                }
            },
          { command: "destroy", title: "", width: "40px" }

        ],


    });


    // code to add Multi Select Combo box to Kendo Grid Cell

    var checkInputs = function (elements) {
        elements.each(function () {
            var element = $(this);
            var input = element.children("input");

            input.prop("checked", element.hasClass("k-state-selected"));

        });
    };
    // create MultiSelect from select HTML element
    function createMultiSelect(e) {
        $(".Multiselectval").append(new Option('ALARM_HANDLER_TASK', enumRemComponents.ALARM_HANDLER_TASK));
        $(".Multiselectval").append(new Option('PERFORMANCE_TASK', enumRemComponents.PERFORMANCE_TASK));
        $(".Multiselectval").append(new Option('REM_DEVICE_AUTH_TASK', enumRemComponents.REM_DEVICE_AUTH_TASK));
        $(".Multiselectval").append(new Option('SERIAL_LINK_TASK', enumRemComponents.SERIAL_LINK_TASK));
        $(".Multiselectval").append(new Option('STATE_MACHINE_TASK', enumRemComponents.STATE_MACHINE_TASK));
        $(".Multiselectval").append(new Option('UNKNOWN_TASK', enumRemComponents.UNKNOWN_TASK));

        var grid = e.sender;
        required = $(".Multiselectval").kendoMultiSelect({
            itemTemplate: "#:data.text# <input type='checkbox'/>",
            autoClose: false,
            dataBound: function () {
                var items = this.ul.find("li");
                setTimeout(function () {
                    checkInputs(items);
                });
            },
            change: function () {
                var items = this.ul.find("li");
                checkInputs(items);
            }
        }).data("kendoMultiSelect");
    }

The above code is working properly.

 

Now i want to select the Multiselect combo values based on the data i got from Database., below is the code i am trying for that, but i am unable to make the values selected.

 var grid = $('#UnitgridPerf').data("kendoGrid");
            grid.dataSource.data(result); 

            for (var j = 0; j < UnitPattern.length; j++) {
                if (PatternName == UnitPattern[j].PatternName) {
                    for (var i = 0; i < UnitPattern[j].Devicestatus[0].ComponentStatus.length; i++) {

                        var gridRows = grid.tbody.find('tr');


                        var row = $(gridRows[i]);
                       
                        var rid = row.find('.Multiselectval');
                        alert(rid[1][UnitPattern[j].Devicestatus[0].ComponentStatus[i].Component].value);

                        
                       rid[1][UnitPattern[j].DeviceStatus[0].ComponentStatus[i].Component].value.checked;

                   

                      // $('.rid option[value=' + UnitPattern[j].DeviceStatus[0].ComponentStatus[i].Component + ']').attr('selected', true);
                    }
                }

Please help on this.

 

Alex Hajigeorgieva
Telerik team
 answered on 27 Oct 2017
6 answers
341 views

Hi,

In Excel there is a setting to set the rows that will repeat at the top of the grid on each page in Page Setup -> Sheet - Print Titles - Rows to repeat at top.

I don't see how to do that in Telerik.Windows.Documents.Spreadsheet. Is it possible?

 

Veselin Tsvetanov
Telerik team
 answered on 27 Oct 2017
1 answer
605 views

Is it possible to make the Radgrid work in the same way as excel so that you can copy and paste a table of data over the top of cells? There is a javascript solution on the market that does this in the right way but I would prefer to do this in MVC using telerik. The example of what I need it to do is: https://www.jqwidgets.com/asp.net-core-mvc-tag-helpers/asp.net-core-mvc-grid-tag-helper/index.htm#https://aspcore.jqwidgets.com/mvc/TagHelpers/GridCellEdit

If somebody could give me a clue as to how this can be done in Telerik, that would be great! Many thanks

 

Tsvetina
Telerik team
 answered on 27 Oct 2017
2 answers
278 views

Hi.  I have a filter in place and I change it at times in js like this.

var ds = $("#scheduler").data("kendoScheduler").dataSource;
           ds.filter([
               {
                   "logic": "or",
                   "filters": [
                       {
                           "field": "OwnerID",
                           "operator": "eq",
                           "value": 1
                       },
                       {
                           "field": "OwnerID",
                           "operator": "eq",
                           "value": 2
                       },
                       {
                           "field": "OwnerID",

In my popup custom edit window I have a dropdown with OwnerID values 1 to 8.

I want the dropdown to show only one default value if my filter is for only 1 value.

My problem is how to read/get data from the current filter.

function filterdata() {
        var scheduler = $("#scheduler").data("kendoScheduler");
        var dataSource = scheduler.dataSource;
        var filters = dataSource.filter();
        alert(filters);  //  this returns the the text "Object"
 
 
      return {
            dept: 2
      };
    }

 

So...  How can I get and check the array values of the filter object?

Thanks

 

Rick Hubka
Top achievements
Rank 1
 answered on 26 Oct 2017
1 answer
108 views

https://docs.telerik.com/aspnet-mvc/getting-started/asp-net-mvc-5

 

Everytime I try to setup a project using Kendo UI with MVC5 the above link never works. I follow it step by step. I just want to setup a project smoothly. 

Dimitar
Telerik team
 answered on 26 Oct 2017
3 answers
118 views

Hi,

unfortunately after upgrading to the latest Version my application has serveral errors. The reason seems to be a bug in server-filtering.

Try

https://demos.telerik.com/aspnet-mvc/grid/serverbinding

Filter column product ID = 1 => It works

Then filter column product ID = 1 OR product ID = 2 => Error

The internal error is a NullReferenceException (see attach file).

Not so good...

Bye, Michael

 

Pavlina
Telerik team
 answered on 26 Oct 2017
2 answers
554 views

I have the Column Menu on my grid to allow users to lock some columns.  However, when I use the columnMenu the filter option shows with the arrow next to it but the sub menu for the filter does not show at all.  Any idea what I am doing wrong? I am using version 2017.3.913.

Here is my grid code:

@model IEnumerable<Saturn.Models.ListData>
<div class="BordRSolThin">
@(Html.Kendo().Grid(Model)
.Name(componentName: "EditGrid")
.DataSource(dataSource => dataSource
.Ajax()
.Read(read => read.Action(actionName: "EditGrid_Read", controllerName: "List")
.Data("getEditData"))
.PageSize(pageSize: 500)
)
.Columns(columns =>
{
columns.Command(command => command.Custom(name: "Edit").Click(handler: "editRevision")).Width(pixelWidth: 75).Locked(true).Lockable(false);
columns.Bound(p => p.CoreID).Title(text: "CoreID").Width(pixelWidth: 100);
columns.Bound(p => p.ProjID).Title(text: "ProjID").Width(pixelWidth: 100);
columns.Bound(p => p.ListRev).Title(text: "ListRev").Width(pixelWidth: 100);
columns.Bound(p => p.SYSID).Title(text: "SYSID").Width(pixelWidth: 100).Locked(true).Lockable(true);
columns.Bound(p => p.FGrp).Title(text: "FGrp").Width(pixelWidth: 300);
columns.Bound(p => p.REDUND).Title(text: "REDUND").Width(pixelWidth: 100);
columns.Bound(p => p.NAME).Title(text: "NAME").Width(pixelWidth: 550).Lockable(true);
columns.Bound(p => p.PlanName).Title(text: "PlanName").Width(pixelWidth: 250).Lockable(true);
columns.Bound(p => p.BarrelType).Title(text: "BarrelType").Width(pixelWidth: 100).Lockable(true);
columns.Bound(p => p.TickNo).Title(text: "TickNo").Width(pixelWidth: 100);                                
                            })
.Pageable(pageable => pageable
.Input(enabled: true)
.Numeric(enabled: false)
.Refresh(enabled: true)
)
.Sortable()
.ColumnMenu()
.Scrollable(scr => scr.Height(pixelHeight: 700))
.Selectable()
.Filterable()
)
</div>

 

 

 

Richard
Top achievements
Rank 1
 answered on 25 Oct 2017
1 answer
340 views

I am creating a Kendo grid with a datetime column. I want to group the date column so that it is descending. The latest date is on top and the earliest on the bottom. I have come across this line of code

groups => groups.AddDescending(true)

 

But it says that there is no definition for AddDescending. How do I change the grouping? Here is how my grid is defined.

@(Html.Kendo().Grid<LogModel>()
            .Name("Log")
            .Columns(columns =>
            {
                columns.Bound(m => m.dateTimeChangeDate)
                    .Title("Date and Time")
                    .ClientTemplate("#= ChangeDate#")
                    .ClientGroupHeaderTemplate("#= formatUtcDateToLocal(value,  'MM/DD/YYYY')#")
                    .Width("12%");
                columns.Bound(m => m.Component)
                    .Title("Component")
                    .Width("8%")
                    .Filterable(filterable => filterable
                        .UI("componentFilter")
                        .Extra(false)
                        .Operators(operators => operators
                            .ForString(str => str.Clear()
                            .Contains("Contains")
                         ))
                );
                columns.Bound(m => m.Action)
                    .Title("Action")
                    .Width("15%")
                    .Filterable(filterable => filterable
                        .UI("actionFilter")
                        .Extra(false)
                        .Operators(operators => operators
                            .ForString(str => str.Clear()
                            .Contains("Contains")
                        ))
                     );
                columns.Bound(m => m.Changer)
                    .Title("Changer")
                    .Width("10%");
                columns.Bound(m => m.Identifier)
                    .Title("On")
                    .Width("15%");
                columns.Bound(m => m.OldValue)
                    .Title("Old Value")
                    .Width("20%");
                columns.Bound(m => m.NewValue)
                    .Title("New Value")
                    .Width("20%");
            })
            .Filterable()
            .Selectable()
            .Sortable()
            .Groupable()
            .Resizable(resize => resize.Columns(true))
            .ToolBar(toolbar =>
            {
            toolbar.Template(
                @<text>
                    <a class="k-button k-button-icontext k-grid-excel" href="#"><span class="k-icon k-i-excel"></span>Export to Excel</a>
                    <span style='padding-left:35%;font-weight:bold;padding-top:7px'>@ViewBag.ProjectNumber</span>
                    <span style='float:right;font-weight:bold;padding-top:7px'>Total: <span id="change-log-record-count">@ViewBag.ChangeLogRecordAmount</span> records</span>
 
                </text>
                );
            })
            .Excel(excel => excel.AllPages(true).FileName(@ViewBag.ChangeLogType + " Change Log " + @ViewBag.ProjectNumber + ".xlsx").Filterable(true))
            .DataSource(dataSource => dataSource
                 .Ajax()
                 .Model(model =>
                 {
                     model.Id(p => p.Id);
                 })
                 .Read(read => read.Action("FetchChangeLogData", "ChangeLog")
                 .Data("buildParam"))
           )
           .Events(e => e.FilterMenuInit("resizeFilter")
                         .ExcelExport("modifyFormatForExcel")
                         .DataBound("preselectCustomFilter"))
           .ClientDetailTemplateId("change-log-details-template")
    )
Stefan
Telerik team
 answered on 25 Oct 2017
3 answers
527 views

How can we select the node that is clicked on by a right click event?  I am trying to pass the selected node's id on a context menu select event but unless the user left clicks on the node to select it first, the last selected node information gets sent, if one was even selected.

This may be fairly basic, but I can't find any examples of this.

Thanks.

Neli
Telerik team
 answered on 25 Oct 2017
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
ComboBox
Upload
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
Dialog
MultiColumnComboBox
DropDownTree
Checkbox
Slider
Switch
Notification
Accessibility
ListView (Mobile)
Pager
Security
ColorPicker
DateRangePicker
Wizard
Styling
Chat
DateInput
MediaPlayer
TileLayout
Drawer
SplitView
Template
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Licensing
Rating
ScrollView
ButtonGroup
DropDownButton
CheckBoxGroup
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
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
SmartPasteButton
PromptBox
SegmentedControl
LLM Kit
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?