Telerik Forums
UI for ASP.NET MVC Forum
4 answers
1.1K+ views
When I navigate to the filter menu in the column menu i am unable to place my cursor in the input box... Meaning if I want to filter by "contains" and I want to type in "something", i cannot type anything in.  It wont even allow me to click on the input boxes.  Its like they are disabled or the focus is not allowed. 

Any ideas?

http://www.telerik.com/forums/kendo-ui-framework

@(Html.Kendo().Grid<DrillDownWSnapshot>()
    .Name("ReportDrillDownWSnapshotGrid")
    .Scrollable(builder => builder.Enabled(true).Height("400px"))
    .HtmlAttributes(new { @class = "cursorLink"})
    .DataSource(ds =>
        ds.Ajax().Read(r => r.Action("DrillDown", "Reports").Data("getDrillDownParameters").Type(HttpVerbs.Post)).PageSize(500)
        )                                    
    .Columns(c =>
        {
            c.Bound(a => a.AccountNumber).Title("Account Number").ClientTemplate("<input type='hidden' id='GridRowURL' value='" + Url.Action("../Workdriver/Account") + "/#=AccountId#' />#=AccountNumber#").Width(150);
            c.Bound(a => a.Product).Title("Product").Width(150);            
            c.Bound(a => a.Source).Title("Source").Width(100);
            c.Bound(a => a.Facility).Title("Facility").Width(100);
            c.Bound(a => a.AdmitDate).Title("Admit Date").Width(150).Format("{0:d}").HtmlAttributes(new { @class = "kendoGridDate" });
            c.Bound(a => a.DischargeDate).Title("Discharge Date").Width(150).Format("{0:d}").HtmlAttributes(new { @class = "kendoGridDate" });
            c.Bound(a => a.List).Title("List").Width(200);
            c.Bound(a => a.Workflow).Title("Workflow").Width(150);
            c.Bound(a => a.Queue).Title("Queue").Width(150);
            c.Bound(a => a.AccountBalance).Title("Account Balance").Width(150).Format("{0:c}").HtmlAttributes(new { @class = "kendoGridCurrency" });            
            c.Bound(a => a.ChargeIntegrityType).Title("Charge Integrity Type").Width(200);
            c.Bound(a => a.ChargeIntegrityReason).Title("Charge Integrity Reason").Width(200);
            c.Bound(a => a.AccountCodeAnomalyGrossOpportunity).Title("Account Code Anomaly Gross Opportunity").Width(300).Format("{0:c}").HtmlAttributes(new { @class = "kendoGridCurrency" });
            c.Bound(a => a.AccountMissingChargeGrossOpportunity).Title("Account Missing Charge Gross Opportunity").Width(300).Format("{0:c}").HtmlAttributes(new { @class = "kendoGridCurrency" });
            c.Bound(a => a.AccountOverchargeGrossOpportunity).Title("Account Overcharge Gross Opportunity").Width(300).Format("{0:c}").HtmlAttributes(new { @class = "kendoGridCurrency" });
            c.Bound(a => a.AccountCodeAnomalyNetOpportunity).Title("Account Code Anomaly Net Opportunity").Width(300).Format("{0:c}").HtmlAttributes(new { @class = "kendoGridCurrency" });
            c.Bound(a => a.AccountMissingChargeNetOpportunity).Title("Account Missing Charge Net Opportunity").Width(300).Format("{0:c}").HtmlAttributes(new { @class = "kendoGridCurrency" });
            c.Bound(a => a.FinancialClassCurrentMC).Title("Financial Class Current MC").Width(200);
            c.Bound(a => a.InsuranceRollupCurrentMC).Title("Insurance Rollup Current MC").Width(215);
            c.Bound(a => a.InsuranceCurrent).Title("Insurance Current").Width(225);
            c.Bound(a => a.PreviousList).Title("Previous List").Width(150);
            c.Bound(a => a.LastActivityDate).Title("Last Activity Date").Width(150).Format("{0:d}").HtmlAttributes(new { @class = "kendoGridDate" });
            c.Bound(a => a.LastActivityUser).Title("Last Activity User").Width(250);
            c.Bound(a => a.LastActivityNote).Title("Last Activity Note").Width(350);
        })   
    .Sortable(s => s.SortMode(GridSortMode.MultipleColumn))
    .Pageable(p =>
        {
            p.Input(true).Numeric(false);
            p.PageSizes(new int[] { 100, 200, 500, 1000 });
        })
    .Filterable(filterable =>
        filterable.Operators(operators => operators
            .ForString(str => str.Clear()
                .Contains("Contains")
                .DoesNotContain("Does not contain")
                .IsEqualTo("Is equal to")
                .IsNotEqualTo("Is not equal to")
                .StartsWith("Starts with")
                .EndsWith("Ends with ")                                
            )
        )
    )
    .ColumnMenu()
    .AutoBind(false)
    .Events(e => e.DataBound("OnDataBound"))
)
Tom
Top achievements
Rank 1
 answered on 11 Jul 2018
5 answers
528 views

This problem is only happening since I update to the latest version (2018.2.620) of UI for ASP.NET MVC from 2016.3.1028.  Yeah, I know - I should keep up.  But the project is in maintenance mode now.

I know this isn't likely much to go on, but I can't imagine how I'd pack the entire project and databases (or fakes thereof) and send it in, so I'm hoping something jumps out and is quite obvious.  Any help appreciated!  Even just a better idea what to look at would be good!

I have a button outside my grid for adding rows.  It triggers .addRow() as follows:

$("#EntryGrid_New").click(function () {
  $("#EntryGrid").data('kendoGrid').addRow();
});

 

When I hit that code, I get the following error:

Unhandled exception at line 26, column 9426 in http://localhost:23159/Scripts/kendo/2018.2.620/kendo.all.min.js
0x800a138f - JavaScript runtime error: Unable to get property '_move' of undefined or null reference occurred

The line it stops on in kendo.all.js is:

    if (arguments.length === 1) {
        return on.call(that, arguments[0]);
    }
    var context = that, args = slice.call(arguments);
    if (typeof args[args.length - 1] === UNDEFINED) {
        args.pop();
    }
    var callback = args[args.length - 1], events = kendo.applyEventMap(args[0], ns);
    if (support.mouseAndTouchPresent && events.search(/mouse|click/) > -1 && this[0] !== document.documentElement) {
        MouseEventNormalizer.setupMouseMute();
        var selector = args.length === 2 ? null : args[1], bustClick = events.indexOf('click') > -1 && events.indexOf('touchend') > -1;
        on.call(this, {
            touchstart: MouseEventNormalizer.muteMouse,
            touchend: MouseEventNormalizer.unMuteMouse
        }, selector, { bustClick: bustClick });
    }
    if (typeof callback === STRING) {
        context = that.data('handler');
        callback = context[callback];
        args[args.length - 1] = function (e) {
            callback.call(context, e);
        };
    }
    args[0] = events;
    on.apply(that, args);
    return that;
},

 

For completeness, here's the definition of the grid:

@(Html.Kendo().Grid<TimePlus.Models.ScheduleExceptionViewModel>()
  .Name("EntryGrid")
  .NoRecords("No exceptions found")
 
  .Columns(columns => {
    columns.Bound(model => model.ExceptionDate);
    columns.Bound(model => model.ExpectedHours).EditorTemplateName("TwoDecimals");
    columns.Command(c => { c.Edit(); c.Destroy().Text("Remove"); }).Width(250);
  })
 
  .Editable(e => e.Mode(GridEditMode.InLine))
  .Events(e => e.Edit("EntryGrid_Edit"))
 
  .DataSource(dataSource => dataSource
    .Ajax()
    .Read(read => read.Action("Schedule_EntryGrid_Read", "Management").Data("GetSelectedDateAndUser"))
    .Destroy(destroy => destroy.Action("Schedule_EntryGrid_Destroy", "Management"))
    .Update(update => update.Action("Schedule_EntryGrid_Update", "Management"))
    .Create(create => create.Action("Schedule_EntryGrid_Create", "Management"))
    .Events(e => e.Error("EntryGrid_Error"))
    .Model(model => {
      model.Id(c => c.ID);
    })
  )
)

 

Georgi
Telerik team
 answered on 11 Jul 2018
1 answer
554 views

Hi All,

I was working on a task to export to excel with 100k rows with 50 columns, but when I click on export to excel it was generating an empty excel .Kindly help me in achieving the task.

Note: This is working well for 6000 rows.

Thanks & Regards,

Sampath

 

Preslav
Telerik team
 answered on 10 Jul 2018
1 answer
139 views

I'm trying to make the text label not crowded in a lot of data and I can not successful.

 

{
dataSource: modelStats,
legend: {
visible: false
},
xAxis: {
min: -2,
max: 2,
labels: {
format: "{0:n1}"
}
},
yAxis: {
labels: {
format: "{0:n2}"
}
},
series: [
{
name: "Fleet Avg",
type: "line",
aggregate: "avg",
field: "fleetAvg",
categoryField: "date",
color: "#a0b751",
},
{
name: "Driver",
type: "line",
aggregate: "avg",
field: "value",
categoryField: "date",
color: "#219dd0",
},
{
name: "Driver previous period",
type: "line",
aggregate: "avg",
field: "valueFrom_SameDateLastPeriod",
categoryField: "date",
color: "#10b4b6",
}
],
seriesDefaults: {
aggregate: "avg",
type: "line",
width: 3,
margin: 30,
markers: {
size: 15,
width: 10
}
},

categoryAxis: {
baseUnit: me.baseUnitDefault[0],
labels: {
dateFormats: {
weeks: tFormat
},
font: "13px Arial,Helvetica,sans-serif",
rotation: "auto"
},
},
tooltip: {
visible: true
},
pannable: true,
onZoom: onChartZoom,
});
Konstantin Dikov
Telerik team
 answered on 10 Jul 2018
6 answers
543 views

https://docs.telerik.com/kendo-ui/api/javascript/ui/grid/events/remove

I am using the above event to refresh other grids on the page when a specific grid has a row deleted.

My test code is as follows:

@(Html.Kendo().Grid<ViewModel>
    ()
    .Name("kGrid")
    .Events(e => {
        e.Remove("alert('hello')");
    })

 

The rest of the code is omitted as it is not relevant.

The "hello" is triggering on page load, and not triggered at all when a row is confirmed removed. Am I missing something? 

Vince
Top achievements
Rank 1
 answered on 09 Jul 2018
5 answers
1.6K+ views

Recently I've been working with telerik devcraft for the last couple of weeks, I'm interested in using the grid controller to display data, I've reached the point where I'm working with CRUD operations and I need to led the user make delete, create and edit operations of the displayed rows my client really doesn't like the way the controller displays the edit and delete buttons next to the rows, he would like to be available to invoke the edit and delete operations via external html buttons on the bottom of the page

 

 

Alex Hajigeorgieva
Telerik team
 answered on 09 Jul 2018
2 answers
918 views

Hi there guys and gals, I have a grid and i am try to hide and show columns based on the selected month from a drop-down list. If selected month is January, then show the JComment column if it is February, then hide the JComment column and show the FComment column. The hide and show functionality works but unfortunately, it breaks the grid appearance, the all columns are compressed in width and blank space on the right of the grid appears. i have tried  calling the resize grid function, i have tried fixing this through css, but to no avail. How  do i fix this?

Here is the Grid logic

@(Html.Kendo().Grid<P2I_UI.Models.ViewM.MinistryImpactVM>()
    .Name("peopleMinistryImpact")
    .Columns(columns =>
    {
        columns.Bound(c => c.StatisticName).Title("StatisticName ").Width(35);
        columns.Bound(c => c.MinistryGroup).Title("Ministry <br/> Group").Width(25);
        columns.Bound(c => c.AgeGroup).Title("Age").Width(25);
        columns.Bound(c => c.AnnualGoal).Title("Annual <br/> Goal").Width(30).ClientTemplate("#=(AnnualGoal == null) ? ' ' : kendo.toString(AnnualGoal,',0')#");
        columns.Bound(c => c.October).Title("Oct.").Width(30).ClientTemplate("#=(October == null) ? ' ' : kendo.toString(October,',0')#");
        columns.Bound(c => c.November).Title("Nov.").Width(30).ClientTemplate("#=(November == null) ? ' ' : kendo.toString(November,',0')#");
        columns.Bound(c => c.December).Title("Dec.").Width(30).ClientTemplate("#=(December == null) ? ' ' : kendo.toString(December,',0')#");
        columns.Bound(c => c.January).Title("Jan.").Width(30).ClientTemplate("#=(January == null) ? ' ' : kendo.toString(January,',0')#");
        columns.Bound(c => c.JanuaryComment).Title("JComment.").Width(50).Hidden();
        columns.Bound(c => c.February).Title("Feb.").Width(30).ClientTemplate("#=(February == null) ? ' ' : kendo.toString(February,',0')#");
        columns.Bound(c => c.FebruaryComment).Title("FComment.").Width(50).Hidden();
        columns.Bound(c => c.March).Title("Mar.").Width(30).ClientTemplate("#=(March == null) ? ' ' : kendo.toString(March,',0')#");
        columns.Bound(c => c.MarchComment).Title("MComment.").Width(50).Hidden();
        columns.Bound(c => c.April).Title("Apr.").Width(30).ClientTemplate("#=(April == null) ? ' ' : kendo.toString(April,',0')#");
        columns.Bound(c => c.May).Title("May.").Width(30).ClientTemplate("#=(May == null) ? ' ' : kendo.toString(May,',0')#");
        columns.Bound(c => c.June).Title("Jun.").Width(30).ClientTemplate("#=(June == null) ? ' ' : kendo.toString(June,',0')#");
        columns.Bound(c => c.July).Title("Jul.").Width(30).ClientTemplate("#=(July == null) ? ' ' : kendo.toString(July,',0')#");
        columns.Bound(c => c.August).Title("Aug.").Width(30).ClientTemplate("#=(August == null) ? ' ' : kendo.toString(August,',0')#");
        columns.Bound(c => c.September).Title("Sep.").Width(30).ClientTemplate("#=(September == null) ? ' ' : kendo.toString(September,',0')#");
        columns.Bound(c => c.FiscalYearToDate).Title("FYTD.").Width(30).ClientTemplate("#=(FiscalYearToDate == null) ? ' ' : kendo.toString(FiscalYearToDate,',0')#");
        columns.Bound(c => c.PercentageOfPlan).Title("% of <br/> Plan.").Width(30).ClientTemplate("#=(PercentageOfPlan == null) ? ' ' : kendo.toString(PercentageOfPlan,'p')#");
    })
    .ToolBar(toolbar =>
    {
        toolbar.Save();
    })
    .Editable(editable => editable.Mode(GridEditMode.InCell))
    .Events(events =>
    {
        events.Edit("onEditMinistryImpact");
    })
    .AutoBind(false)
    .DataSource(dataSource => dataSource
    .Ajax()
    .Sort(s =>
    {
        s.Add(p => p.SortOrder).Ascending();
        s.Add(p => p.MinistryGroupCategoryID).Ascending();
        s.Add(p => p.AgeCategoryID).Ascending();
    })
    .ServerOperation(false)
    .Batch(true)
    .Model(model =>
    {
        model.Id(p => p.MinistryImpactID);
        model.Field(p => p.StatisticName).Editable(false);
        model.Field(p => p.MinistryGroup).Editable(false);
        model.Field(p => p.AgeGroup).Editable(false);
        model.Field(p => p.FiscalYearToDate).Editable(false);
        model.Field(p => p.PercentageOfPlan).Editable(false);
    })
     .Read(read => read.Action("MinistryImpact_Read", "MinistryImpact").Data("additionalData"))
     .Update(update => update.Action("MinistryImpact_Update", "MinistryImpact"))
    )
)

 

Js Logic

function onMonthChange(e)
{
    var selectedMonthIndex = this.value();
    var peopleMinistry = $("#peopleMinistryImpact").data("kendoGrid");
 
    if (parseInt(selectedMonthIndex) === parseInt(0))
    {
        peopleMinistry.showColumn("JanuaryComment");
        peopleMinistry.hideColumn("FebruaryComment");
        peopleMinistry.hideColumn("MarchComment");
    }
    else if (parseInt(selectedMonthIndex) === parseInt(1)) {
        peopleMinistry.hideColumn("JanuaryComment");
        peopleMinistry.showColumn("FebruaryComment");
        peopleMinistry.hideColumn("MarchComment");
    }
    else if (parseInt(selectedMonthIndex) === parseInt(2)) {
        peopleMinistry.hideColumn("JanuaryComment");
        peopleMinistry.hideColumn("FebruaryComment");
        peopleMinistry.showColumn("MarchComment");
    }
       peopleMinistry.resize();
        // force the layout readjustment without setting a new height
       peopleMinistry.resize(true)
}

CSS

<style>
    #peopleMinistryImpact.k-grid-header {
        padding: 0 !important;
    }
 
    #peopleMinistryImpact.k-grid-content {
        overflow-y: visible;
    }
 
    #peopleMinistryImpact > .k-grid-header > div > table,
    #peopleMinistryImpact > .k-grid-content > table {
        width: 100% !important;
    }
 
    #peopleMinistryImpact {
        min-width: 1250px;
    }
</style>

 

Thanks for the help

Chinonso
Top achievements
Rank 1
 answered on 05 Jul 2018
2 answers
99 views

Hello,

I have an application, in wich there is a combobox above a grid. If i choose a company in the Combobox, then the people of the company are shown in the grid.

I have now the problem with the edit button in the grid. If I change the company and after this click on the edit button, the edit popup do not open. Instead the grid fires the Read-Action. When i click a second time on the edit button, the edit popup is opening.

I attached a demo project with this problem. I remvoed the Kendo Css-files and Scripts to get a small zip-File. Just Reinstall the "Telerik.UI.for.AspNet.Mvc5" package. I use the version 2018.1.117

Thank you for your help.

Ralf

Ralf
Top achievements
Rank 1
 answered on 05 Jul 2018
3 answers
130 views

Hello,

Could some one help me the sorting issue? Records cannot be sorted  by clicking on a column's header after I applying group on the grid. I am working on MVC project. 

Thanks in advance.

 

Alex Hajigeorgieva
Telerik team
 answered on 03 Jul 2018
3 answers
234 views

     I need to show the details of the grid for CRUD operations outside the grid (in a tabbed layout with the details and subgrids). The template is the same used in popup but it has to be in the same page that the grid.

 

  Is there any way to achieve this? I've seen this example in the documentation but it's for jquery

 

http://dojo.telerik.com/upiPE/26

 

Thank you

Georgi
Telerik team
 answered on 03 Jul 2018
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
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
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
SmartPasteButton
PromptBox
SegmentedControl
LLM Kit
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?