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

Hi Kendo Team,

We are using kendo MVC textboxes, dropdowns, Grids, etc controls on our application pages.

We have used the @Html.Kendo().DeferredScripts(true) on the pages. However, we are seeing that this is taking close to 1 sec in the browser. All our APIs are returning data in less than 500 ms, but this causes the page to be rendered in close to 2 sec, when it could be faster.

Please advise if there is a way to improve the performance of @Html.Kendo().DeferredScripts(true)

Thanks,

Faraaz

Neli
Telerik team
 answered on 03 Feb 2021
3 answers
73 views

How can I let users paste '   123456  ' into my numeric textbox and have it auto-strip the spaces? There are spaces in the beginning and in the end too. 

currently if there is any space at the beginning or at the end, it doesn't paste anything, show some sign of exclamation and value disappears.

 

<kendo-numerictextbox  k-format="'#'"  ng-model="searchParams.@Model.ParameterName">
        </kendo-numerictextbox>

I also tried this where I am making dynamically kendo control as shown below:

<input kendo-numeric-text-box k-format="'#'"  ng-model="searchParams.@Model.ParameterName" />

I have tried every possible solution, 

Can you please assist how can I achieve this in Angular JS ?

 

Thanks, 

Umair.

Anton Mironov
Telerik team
 answered on 02 Feb 2021
1 answer
767 views

Hi,

I am trying to achieve the functionality of inserting a partial view with grid model property attached to it. Can you please help me?

Tsvetomir
Telerik team
 answered on 02 Feb 2021
1 answer
631 views

How to render a textarea in the Form? I have the below code, it did increase the height of the textbox, but does not behave like textarea.

 

items.AddGroup()
    .Label("Comments")
    .Layout("grid")
    .Grid(g => g.Cols(1).Gutter(10))
    .Items(i =>
    {
        i.Add()
             .Field(f => f.Comments)
             .Label(l => l.Text("Comments:")).InputHtmlAttributes(new { style = "height:80px;" });
    });

 

 

 

Thank  you!

Martin
Telerik team
 answered on 01 Feb 2021
1 answer
124 views
Some of the directories I'm listing in the file manager should not be able to accept files being copied or moved into them when an associated record has a certain status. I have scripts working that fire on CopyCommand and MoveCommand, which query a database via an API call. However, I only seem to be able to access the source path in these scripts. Is there a way to also retrieve the destination path?
Neli
Telerik team
 answered on 01 Feb 2021
4 answers
231 views

Working on integrating a Kendo.DropDownList() into a Kendo.Filter object.

It currently works in everyway, other than actually supplying the selected value from the DDL into the datasource / grid binding.

How do I map the Value selected in the Filter Editor Template to the datasource / grid binding. I just need to pass the selected words to be used in the code behind query.

Current Implementation (DDL):

@(Html.Kendo().Filter<KitValidationDtoModel>()
    .Name("filter")
    .ApplyButton()
    .ExpressionPreview()
    .MainLogic(FilterCompositionLogicalOperator.And)
    .Fields(f =>
    {
        f.Add(p => p.OrderId).Label("Davidson Order ID");
        f.Add(p => p.EdiOrderId).Label("EDI Order ID");
        f.Add(p => p.Rfid).Label("RFID Tracker");
        f.Add(p => p.Assy).Label("ASSY");
        f.Add(p => p.Control).Label("Control Point").EditorTemplateId("controlTemplate");
        f.Add(p => p.Ei).Label("End Item");
        f.Add(p => p.Ship).Label("Ship");
    })
    .FilterExpression(f =>
    {
        f.Add(p => p.Control).IsEqualTo("");
        f.Add(p => p.Ship).Contains("");
    })
    .DataSource("dataSource1"))

 

<script type="text/x-kendo-template" id="controlTemplate">
    @(Html.Kendo().DropDownList()
                  .Name("control_filter_dll")
                  .OptionLabel("Select Control Point...")
                  .DataTextField("Control")
                  .DataValueField("Control")
        .DataSource(source =>
        {
            source.Read(read =>
            {
                read.Action("GetControlPoints", "CustomOrder");
            });
        }).Events(e => e.Change("onControlChange")).ToClientTemplate())
</script>

Headygains
Top achievements
Rank 1
Veteran
 answered on 29 Jan 2021
2 answers
1.0K+ views

 

Hello,

My MVC project used Kendo Grid with pagination functionality.  How to set width of pagesize dropdown list without impacting other kendo dropdown list in the same page?  Thanks.

 

Daochuen
Top achievements
Rank 1
Iron
Veteran
Iron
 answered on 29 Jan 2021
2 answers
1.2K+ views

When I call the Create method of kendo grid its giving an exception - ''"An item with the same key has already been added". I checked that their is no any duplicate property name in the model, Only one grid on the page. Not sure what causing this error. Appreciate your help in advance.

Inner Exception : 

at System.ThrowHelper.ThrowArgumentException(ExceptionResource resource)<br>   at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)<br>   at System.Collections.Generic.CollectionExtensions.ToDictionaryFast[TKey,TValue](TValue[] array, Func`2 keySelector, IEqualityComparer`1 comparer)<br>   at System.Web.Mvc.ModelBindingContext.get_PropertyMetadata()<br>   at System.Web.Mvc.DefaultModelBinder.BindProperty(ControllerContext controllerContext, ModelBindingContext bindingContext, PropertyDescriptor propertyDescriptor)<br>   at System.Web.Mvc.DefaultModelBinder.BindProperties(ControllerContext controllerContext, ModelBindingContext bindingContext)<br>   at System.Web.Mvc.DefaultModelBinder.BindComplexElementalModel(ControllerContext controllerContext, ModelBindingContext bindingContext, Object model)<br>   at System.Web.Mvc.DefaultModelBinder.BindComplexModel(ControllerContext controllerContext, ModelBindingContext bindingContext)<br>   at System.Web.Mvc.DefaultModelBinder.BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext)<br>   at System.Web.Mvc.ControllerActionInvoker.GetParameterValue(ControllerContext controllerContext, ParameterDescriptor parameterDescriptor)<br>   at System.Web.Mvc.ControllerActionInvoker.GetParameterValues(ControllerContext controllerContext, ActionDescriptor actionDescriptor)<br>   at System.Web.Mvc.Async.AsyncControllerActionInvoker.<>c__DisplayClass3_1.<BeginInvokeAction>b__0(AsyncCallback asyncCallback, Object asyncState)

 

 

Grid : 

@(Html.Kendo().Grid<PersonViewModel>(false)

                            .HtmlAttributes(new { @style = "height: 100%;" })
                            .Name("ContactGrid")
                            .ToolBar(toolbar => toolbar.Create())
                            .toolbar(tools =>
                            {
                                tools.custom().name("addnewcontact").text("add new contact".translate()).htmlattributes(new
                                {
                                    id = "addnewcontact"
                                });
                            })
                            .Excel(e => { e.Filterable(true); e.AllPages(true); e.ForceProxy(true); e.ProxyURL("/Localized/" + nameof(LocalizedController.ExportToExcel)); })
                            .Editable(e =>
                            {
                                e.Enabled(true)
                                .DisplayDeleteConfirmation(true)
                               .Mode(GridEditMode.PopUp).TemplateName("PersonEditor")
                                .Window(w =>
                                {
                                    w.Scrollable(true)
                                    .Resizable()
                                    .Height(245).Width(400);
                                });
                            })

                    .DataSource(datasource => datasource
                    .Custom()
                    .Type("aspnetmvc-ajax")
                    .Transport(t =>
                    {
                        t.Read(r => r.Action("Contacts_Read", "DynamicDiscountingOffer").Data("getAdditionalData").Type(HttpVerbs.Get));
                        t.Create(c => c.Action("Contacts_Create", "DynamicDiscountingOffer").Data("getAdditionalDataToCreateContact"));
                        t.Create(c => c.Action("Contacts_Create", "DynamicDiscountingOffer"));
                    })

                    .Schema(s => s
                    .Model(model =>
                    {
                        model.Id(p => p.VR_PersonId);
                        model.Field(nameof(PersonViewModel.VR_Id), typeof(int?)).DefaultValue(VrId);
                        model.Field(nameof(PersonViewModel.FirstName), typeof(string));
                        model.Field(nameof(PersonViewModel.LastName), typeof(string));
                        model.Field(nameof(PersonViewModel.Email), typeof(string));
                    })
                    .Errors("Errors")
                    .Data("Data")
                    .Total("Total")
                    )
                    .PageSize(10)
                    .ServerSorting(true)
                    .ServerPaging(true)
                    .ServerFiltering(true)
                    .ServerGrouping(false)
                    .ServerAggregates(false)
                    .Events(events => events.Error("error_handler"))
                   )
                   .Pageable(p => { p.Refresh(true); p.PageSizes(new int[] { 10, 20, 50, 100, 200, 2000, 5000 }); })
                    .Columns(columns =>
                    {
                        columns.Bound(c => c.FirstName).Width(140);
                        columns.Bound(c => c.LastName).Width(190);
                        columns.Bound(c => c.Email).Width(250);
                        columns.Command(command =>
                        {
                            ///command.Edit().UpdateText("Submit".Translate()).Visible("editVisible").Text("Edit".Translate());
                            command.Custom("View").Visible("viewVisible").Text("View".Translate()).Click("showDetails");
                            command.Custom("Delete").Visible("deleteVisible").Text("Delete".Translate()).Click("DeleteRow");
                        }).Width(85).MinResizableWidth(85);

                    }
    )
    )

 
[DataContract]
    [Serializable]
    public class PersonViewModel : IValidatableObject
    {
        public int VR_PersonId { get; set; }
 
        [DataMember]
        public int VR_Id { get; set; }
 
        [DataMember]
        public string VendorId { get; set; }
 
        [DataMember]
        public Nullable<Guid> UserId { get; set; }
         
        [DataMember]
        public Nullable<System.DateTime> StartDate { get; set; }

}

 

Anton Mironov
Telerik team
 answered on 29 Jan 2021
2 answers
147 views
I would like my users to be able to renamed or delete files, but not folders. I found the post asking how to prevent subfolders from being created, but delete and renaming seem to be different animals.
Responsive
Top achievements
Rank 1
Veteran
 answered on 28 Jan 2021
1 answer
800 views

Does the ExpansionPanel allow for nested objects within individual panels?

Will it handle the Telerik Grid or Tabs (with even more nesting)?

Is there any change required to make the nested items responsive?

Can the content be loaded using ajax (independently per panel)?

Georgi
Telerik team
 answered on 28 Jan 2021
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
Licensing
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
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?