Telerik Forums
UI for ASP.NET MVC Forum
1 answer
1.3K+ views

Please refer attached screen shot.

I have parent and child grids. Child grid has Export to Excel button. When we click Export to Excel in child grid, it should export the expanded row as well as all child grid rows. Right now I can export child grid data only.

Viktor Tachev
Telerik team
 answered on 15 May 2017
21 answers
1.1K+ views
Hi, after loading state for a grid, the toolbar disappears.  Also, the Scrollable.Height property is no longer recognized and grid auto-sizes.  Basically, I'm trying to save the user's grid state on every dataBound event.  Then on initial load of page, the user's grid state is loaded.  Any ideas?

function onDataBound(arg)
{
    var grid = $("#UserAdministrationUserGrid").data("kendoGrid");
 
    if (initialLoad) {
        var options = localStorage["kendo-grid-options"];
        if (options) {
            grid.setOptions(JSON.parse(options));
        }
 
        initialLoad = false;
    }
 
    localStorage["kendo-grid-options"] = kendo.stringify(grid.getOptions());
}

Stefan
Telerik team
 answered on 15 May 2017
1 answer
122 views

Hi Team,

We are using cascaded multiselects with serverfiltering set to true.

But when we are typing some characters in the second multiselect, the suggestions are not showing up.

However it is working fine with serverfiltering set to false but in this case the second multiselect is not filtering on selection from first multiselect.

First Multiselect:

@(Html.Kendo().MultiSelect()
                                .Name("drp_Sector")
                                .DataTextField("SectorName")
                                .DataValueField("SectorId")
                                .Placeholder("Select").HtmlAttributes(new { @class = "drpWidth fontforcontrol" })
                                .Events(e =>
                                { e.Change("onChange_SectorPreDefinedComps").DataBound("onDataBound_SectorPreDefinedComps").Filtering("OnFilter_SectorPreDefinedComps");
                                })
                                .DataSource(source =>
                                {
                                    source.Read(read =>
                                    {
                                        read.Action("GetSectors", "ManageComps");
                                    }).ServerFiltering(true);
                                }).AutoBind(false)
                                )

Second Multiselect:

@(Html.Kendo().MultiSelect()
                                .Name("MulSel_SubSector")
                                .DataTextField("SubSectorName")
                                .DataValueField("SubSectorId")
                                .Placeholder("Select")
                                .AutoBind(false)
                                .HtmlAttributes(new { @class = "fontforcontrol" })
                                .Enable(false)
                                .Events(e =>
                                {
                                    e.Change("onChange_SubSectorPreDefinedComps").DataBound("onDataBound_SubSectorPreDefinedComps");

                                })

                                .DataSource(source =>
                                {
                                    source.Read(read =>
                                    {
                                        read.Action("GetSubSectors", "TickComp")
                                        .Data("PostSectorIdPreDefined");
                                    }).ServerFiltering(true);
                                }))

 

Please help asap.

Thanks in advance,

Abhinav

Nencho
Telerik team
 answered on 15 May 2017
5 answers
628 views
can anyone tell me how I can determine the version of the JQuery library the cdn uses ?  When I convert an mvc4 app to kendo ui, this gets added to the layout page

 <script src="http://cdn.kendostatic.com/2012.3.1114/js/jquery.min.js"></script>

how canj I ensure Im using the latest version ?  (currently v1.9.0)
Dimo
Telerik team
 answered on 15 May 2017
3 answers
354 views

Hi,

I'm not able to get the drag handler in the task progress bar.I want implement drag handler to change the percent complete. This is my code

@(Html.Kendo().Gantt<TaskGanttFacade, TaskGanttDependencyFacade>((IEnumerable<TaskGanttFacade>)ViewBag.Tasks, (IEnumerable<TaskGanttDependencyFacade>)ViewBag.Dependencies)
          .Name("gantt")
                  .DataSource(ds => ds.Read(read => read
                                    .Action("Tasks", "Home")
                                )  
              .Model(m =>
              {
                  m.Id(f => f.Id);
                  m.ParentId(f => f.ParentId);
                  m.OrderId(f => f.OrderId);
                  m.Field(f => f.Expanded).DefaultValue(true);
              })
          )
                  .DependenciesDataSource(ds => ds.Read(read => read
                                    .Action("Dependencies", "Home")
                                )
              .Model(m =>
              {
                  m.Id(f => f.DependencyId);
                  m.PredecessorId(f => f.PredecessorId);
                  m.SuccessorId(f => f.SuccessorId);
                  m.Type(f => f.Type);
              })
          )

          .Columns(columns =>
          {
              columns.Bound("title").Editable(true).Sortable(true).Width(200);
              columns.Bound("Owner").Editable(true).Sortable(true).Width(75);
              columns.Bound("Property").Editable(true).Sortable(true).Width(50);
              columns.Bound("end").Title("End Time").Format("{0:MM/dd/yyyy}").Width(75).Editable(true).Sortable(true);
          })
          .Views(views =>
          {
              views.WeekView(weekView => weekView.Selected(true));
              views.MonthView();
          })
          .Events(events => events
              .DataBound("onDataBound")
          )
          .Height(500)
          .ListWidth("450")
          .ShowWorkHours(false)
          .ShowWorkDays(false)
          .Snap(false)
          .Resizable(true)
          .Editable(false)
    )

Can use please let me know if I have missed something or how can I implement it?

I tried using task template and added a div with class="k-task-draghandle" but I was not able to drag that.

I have also attached the image of my gantt chart for reference.

Thanks,

Keerthana

Ivan Danchev
Telerik team
 answered on 12 May 2017
3 answers
403 views

Hi,
I am using an HTML Button (Say Save) Outside Kendo Grid toolbar to save the data.
On Button click I have called the JavaScript function and from JavaScript I am calling the saveChanges method that fires my events in controller.
I have following four events written in controller.   
Editing_Create, Editing_Update, Editing_Destroy and Save. The events are also getting fired.
My question is if I add, update and delete some records from the grid and hit the Save Button, what is the sequence in which the above four controller action will get executed. Currently it is getting executed in any random order each time.

Please advice.

Regards,
Mahendra

Stefan
Telerik team
 answered on 12 May 2017
1 answer
169 views
Whenever a tooltip is created, the .k-tooltip div is placed on the body. I need the tooltip elements to be placed inside a div on the body.
Ivan Danchev
Telerik team
 answered on 12 May 2017
1 answer
571 views

Hi,

I need to get hold of the Column click event,I managed to get the row click event through 'onchange',I was able to set a class for this particular column too but I am clueless on how to identify the column on which the click event took place.Please help me out here.

Thanks in advance,

Didi

Nencho
Telerik team
 answered on 12 May 2017
2 answers
102 views

Hello,

I'm stumped, and could use some direction. If you can provide me a clue, I'd appreciate it.

In my app, I have a view containing a grid. Each row of the grid corresponds to a Job. Each Job has a Schedule, itself an object, as one of the Job's members.

So, from this grid in which each row corresponds to a Job, I need to be able to open a partial view in which to edit a Job's schedule. (In each row, I can edit the Job data members that are simple types. But to edit its Schedule, I need to open a partial view.)

I am aware that there is a Window control. That may be the appropriate mechanism for opening the partial view. There is the matter of passing the appropriate model object to the partial view, which would be the Job's Schedule.

Here's what the grid looks like, minus any column for the Schedule (I don't know what that looks like yet.)

 

@Html.Kendo().Grid(Model).Name("JobsRecurringGridEx").DataSource(d => d.Ajax()
        .Model(m =>
        {
            m.Id(o => o.ID);
            m.Field(o => o.ID).Editable(false);
        })
        .Batch(true)
        .Read(r => r.Action("GetJobsRecurringAll", "JobsRecurring"))
        .Update(r => r.Action("UpdateJobsRecurring", "JobsRecurring"))
        .Create(r => r.Action("AddJobsRecurring", "JobsRecurring"))
        ).Columns(col =>
        {
            col.Bound(o => o.ID);
            col.Bound(o => o.JOB_NAME).EditorTemplateName("String");
            col.Bound(o => o.DBID).EditorTemplateName("String");

            col.Bound(o => o.PARAMETER_1).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_2).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_3).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_4).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_5).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_6).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_7).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_8).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_9).Hidden(true).EditorTemplateName("String");
            col.Bound(o => o.PARAMETER_10).Hidden(true).EditorTemplateName("String");

            col.Bound(o => o.START_RUN_DATE_TIME);
            col.Bound(o => o.LAST_RUN_DATE_TIME);
            col.Bound(o => o.NEXT_RUN_DATE_TIME).EditorTemplateName("DateTime");
            col.Bound(o => o.SEED_RUN_DATE_TIME).EditorTemplateName("DateTime");

            col.Bound(o => o.RUN_INTERVAL).EditorTemplateName("Integer");
            col.Bound(o => o.ACTIVE);
            col.Bound(o => o.PAUSED).Hidden(true);
            col.Bound(o => o.CREATED_BY).Hidden(true).EditorTemplateName("String"); ;
            col.Bound(o => o.CREATED_DATE_TIME).Hidden(true).EditorTemplateName("DateTime");
         
        }).Editable(e => e.Mode(GridEditMode.InCell)).ToolBar(tb => { tb.Create(); tb.Save(); }).Sortable().Filterable().Pageable()

 

The partial view that I need to use in order to edit a Job's Schedule is "~/Views/JobSchedule/_Index.cshtml".

 

 

 

 

 

 

Help
Top achievements
Rank 1
 answered on 11 May 2017
6 answers
5.5K+ views
I am trying to add HTML5 data- attributes to a data bound column in an MVC grid.

I'm looking for something like this without having to resort to using a template.  Obviously, the syntax in the new object is invalid because of the hyphens.
columns.Bound(i => i.InvoiceNumber).Title("Company").HtmlAttributes(new { data-company-id = @item.CompanyId});

Is there a way to accomplish this?
li
Top achievements
Rank 1
 answered on 11 May 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
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
+? 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?