Telerik Forums
Kendo UI for jQuery Forum
1 answer
112 views

Per:
https://demos.telerik.com/aspnet-core/grid
can someone provide/post the source for the Editor Templates Names for Country and ClientCategoryEditor?

I'm trying to make an editable  grid with a select control in one of the columns (Country), just like the demo...  but the source code/markup  seems to be incomplete...
I'm looking for the source editor templates behind these:

 columns.Bound(p => p.Country.CountryNameLong).Title("Country").EditorTemplateName("Country")

 columns.Bound(=> p.Category.CategoryName).EditorTemplateName("ClientCategoryEditor")

fyi these are broken in  the edit in teletik repl as well....

maybe if it was a snake it would have bit me...

Thanks

Aleksandar
Telerik team
 answered on 16 Dec 2021
0 answers
191 views

I'm trying to get the validation working on my form with kendovalidator

I'm using Telerik ver : 2019.2.619

    $.validator.setDefaults({
        ignore: ""
    });
    $(function () {
        $("#form1").kendoValidator();
    });

this shows validation messages correctly if values are empty eg:

issue is  when an incorrect value is entered the message shows:

 


    <div class="form-group row">
        @Html.LabelFor(model => model.CountryCodeId, htmlAttributes: new { @class = "control-label col-md-2 required" })
        <div class="col-md-10">
            @(Html.Kendo().ComboBoxFor(m => m.CountryCodeId)
                                         .Name("CountryCodeId")
                                        .Placeholder(@Resources.Resources.CountryPlaceholder)
                                        .DataTextField("Description")
                                        .DataValueField("Id")
                                        .Filter("contains")
                                        .Suggest(true)
                                        .DataSource(s => s.Read(r => r.Action("GetCountries", "Customer")).ServerFiltering(false))
                                        .HtmlAttributes(new {  style = "width:300px" })
            )
            @Html.ValidationMessageFor(model => model.CountryCodeId, "", new { @class = "text-danger" })
        </div>
    </div>



        [Required(ErrorMessageResourceType = typeof(Resources.Resources), ErrorMessageResourceName = "CountryValidation")]
        [Display(ResourceType = typeof(Resources.Resources), Name = "Country")]
        public int? CountryCodeId { get; set; }

and if  I enter a number the validation seems to pass, which it shouldn't

Validation should pass only if a country is selected from the combobox, entrering a numeric value or any other text which is not on the list should fail validation

How do I get default dataanotation message if an invalid entry is made?

Thanks

 

Faz
Top achievements
Rank 1
Iron
 updated question on 23 Aug 2021
1 answer
63 views

Hi,

I have a combbox where the choices are driven by a remote datasource as follows:

main.php
-----------------------
<script>
var dataSource = new kendo.data.DataSource({
    transport: {
        read: {
            url: "select_data3.php?type=123",
            dataType: "json"
        }
    }
});

$("#event_id").kendoComboBox({
    dataTextField: "Text",
    dataValueField: "Value",
    filter: "contains",
    dataSource: dataSource,
    placeholder: "Select a product",
});
</script>

<select id="event_id" style="width: 450px;">
</select>

 

select_data3.php
-----------------
<?php header('Content-Type: application/json');?>
[{"Text":"AUT","Value":"Austria"}, {"Text":"BEL","Value":"Belgium"}, {"Text":"BGR","Value":"Bulgaria"}]


It's unable to load remote data into combobox


And i had tried to
1. copy http://dojo.telerik.com/IzAWU to my localhost
2. download //demos.telerik.com/kendo-ui/service/Products to local folder
3. It's good for execute step1 directly
4. Show nothing, when i modify params to "//localhost/test/Products" and "json"


Neli
Telerik team
 answered on 27 May 2021
1 answer
25 views

I have Asp.net website , and telerik controls on it.  On page load I get ConvertFontToSpanfilter error as a alert. On clicking few times 'OK' on alert i am able to process normal.

I am not able to figure it out why it's happening . As i know we can disable the filter but is there any specific reason it's happening?

Neli
Telerik team
 answered on 17 May 2021
1 answer
235 views

Hello. I am using a custom column editor as shown in your example : https://docs.telerik.com/kendo-ui/knowledge-base/custom-editor-autocomplete. Even in the example that you provided, if I type a value that is not in the list, on focus out the field will display "undefined" and will remain this way even if i try to select another value. Is there a fix for this situation? Thank you in advance :)

I attached a screenshot from your working example.

Martin
Telerik team
 answered on 11 May 2021
1 answer
88 views

In chrome mobile browser when a combo is searched and clicked, combo box gets cleared sometimes. In other browsers this issue is not there. 

Step 1 : type 2 or 3 three characters in combo box.

Step 2 : click on desired value

Result : Half of the time, combo box gets cleared. 

Dimitar
Telerik team
 answered on 27 Apr 2021
1 answer
79 views

Hi,

I tried the following code to refresh the list items of a ComboBox widget, but it didn't work.  It didn't trigger a data retrieval call.  Not sure what's wrong.

    widget.dataSource.read();
    widget.refresh();

 

The data source is created as follows:

new kendo.data.DataSource({
    serverFiltering: true
    transport: {
        read: {
            url: "xxxx",
            dataType: "json",
            data: function (e) {
                // some code to dynamically prepare the call parameters
            },
            type: "POST"
        }
    },
    schema: {
        data: function (response) {
            if (response != null) {
                var result = JSON.parse(response);
                return (result.Data != null ? result.Data : "");
            } else {
                return "";
            }
        }
    }
});

 

Please advise.  Thanks.

Martin
Telerik team
 answered on 23 Mar 2021
5 answers
62 views

Hello, I'm find multi identifiable combo box. Is it implement?

current combobox

준호
Top achievements
Rank 1
 answered on 16 Mar 2021
1 answer
215 views

I have a kendo combobox to determine what data is being called in the sql backend. The rows from the sql table are added to a table element below the combobox and one of those elements is a button that saves the data when edited. For some reason when i change to another client at times it will call the button event to save an item in the table but apply it to the next combobox value and leads to data being copied from one client to the other. Not sure how to being fixing this issue but I have isolated it to the change event via loggers.

here is some code : 

<form id="form1" runat="server" autocomplete="none"> <div id ="lineitemeditdiv" runat="server" style="padding:1%;"> Companies : <select id="clientbillingcompanies" runat="server"></select><br/> <script> window.onload = function() { //$('#clientbillingcompanies').chosen({change: onChangeKB}); $('#clientbillingcompanies').kendoComboBox(); $("#clientbillingcompanies").parent().css('width',"50%"); $("#clientbillingcompanies").data('kendoComboBox').input.attr('autocomplete','off'); $("#clientbillingcompanies").data('kendoComboBox').bind("change", onChangeKB) }; </script> <table id="lineitemtable" runat="server" > </table> <br /> <button id="submitlineitem" >Add</button> </div> </form>

Neli
Telerik team
 answered on 07 Dec 2020
7 answers
4.2K+ views
Hello,

Is there a way to restrict kendo combobox being edited manually but only allow the user to select from the dropdown values. If yes would you give an example in razor please?

I also want to allow the user to edit to a valid date in a kendo datepicker but not any other text. Is that possible?

Thanks
Floris
Top achievements
Rank 1
Iron
 answered on 07 Nov 2020
Narrow your results
Selected tags
Tags
+? more
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?