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

Hi,

i have a cascading dropdown list inside grid. when i click ass row and  when i click 2nd drop down able to load data without selecting first dropdown. so here first i want to disable 2nd dropdown and after selecting 1st drop down i want to enable 2nd dropdown  with the values depends on first drop down.

Anton Mironov
Telerik team
 answered on 13 Sep 2021
15 answers
4.8K+ views
Hi,

I am evaluating the kendo controls for purchase and I am having trouble setting a kendo dropdown to readonly in mvc 4 using the razor view engine. I keep getting the error

0x800a01b6 - Microsoft JScript runtime error: Object doesn't support property or method 'readonly'

My solution is a little more complex but basically I have the below code with a bunch of stuff cut out. Everything works fine until i want to set the dropdown to read only on page load in one of my cases. It seems like I am following the documentation but i can't see to figure out what is wrong.  I've spent a good few hours on this and am out of tricks. I've got access to the dropdown for click events that i set on buttons and such but not during the $(document).ready.

I feel like something in .readonly() is using something not in my jquery but that is only a wild guess.

Thanks in a advance

<script>
//.readonly()doesn't work
  $(document).ready(function () {
        var something = $("#ProvinceRegion").data("kendoDropDownList");
        something.readonly();

//note: something.enable(false); works here just readonly() doesn't

});


//notice I can set .enabled on this function below
    function ClearCustomerClick() {

//all the below work
        var dropdownlist = $("#CustomerName").data("kendoDropDownList")
        dropdownlist.select(0);
        var billContactList = $("#BillingContact").data("kendoDropDownList")
        billContactList.enable(false);
        var billSiteList = $("#BillSite").data("kendoDropDownList")
        billSiteList.enable(false);

    }

</script>

and then my dropdown list is below

@using (Html.BeginForm("ProjectSetupDetails", "Setup", FormMethod.Post, new { enctype = "multipart/form-data" }))
{
                    @(Html.Kendo().DropDownList()
                        .Name("ProvinceRegion")
                        .OptionLabel("Pick a region...")
                        .BindTo(Model.RegionList))

}
AGGELIKI
Top achievements
Rank 1
Iron
 answered on 10 Sep 2021
1 answer
548 views

Hi,

here i want to display alternate colors with different color for new row inside kendo grid incell edit mode.

Petar
Telerik team
 answered on 09 Sep 2021
1 answer
229 views

Hello 

I used Telerik UI for ASP.NET MVC Grid to perform CRUD operations and manipulate its data in Popup mode. I create a template to customize the Popup window .. Until now every things works fine except the binding in the drop down list .. I followed exactly this demo but unfortunately the drop down list won't to populate. 

Also, When I want to used a foreignkey column in Grid as below, I got "Value can not be null" error :(

columns.ForeignKey(p => p.category_id, ds => ds.Read(r => r.Action("GetCategories", "Home")), "id", "name").Title("Category");

I attached sample project having the issue.

Any Help Please

Eyup
Telerik team
 answered on 09 Sep 2021
0 answers
149 views

I have a stranger issue, The Kendo Grid for ASP.Net MVC work as expect except when I added any event for ant tool in the popup template, The popup window opens in the same page not poping up

Any Idea?

Abdulsalam Elsharif
Top achievements
Rank 2
Iron
Iron
 asked on 08 Sep 2021
0 answers
279 views

Hi,

I have a Kendo Editor control on one of my pages which I've enabled the "paste cleanup" feature on with the flags "all" and "css" but when I copy/paste content with HTML tags and inline CSS styles into it, those tags/styles are not being removed as expected.

This can be seen on the paste cleanup feature demo page - https://demos.telerik.com/kendo-ui/editor/paste-cleanup when pasting in the following HTML snippet

<h1 style="text-align:center;"><strong>The simple way to get a brand new bike, make huge savings and spread the cost</strong></h1>

 

I've tried various combinations of the options available on that page but nothing works so is there a way of achieving the expected result?

 

 

Lee
Top achievements
Rank 1
 asked on 08 Sep 2021
1 answer
264 views

Hello

I used popup window to edit a row in grid, I want to know how can I customize the popup windows (Edit title, Size, Hide some fields, Submit button title ,,, etc)

Anyone can help please? 

Petar
Telerik team
 answered on 03 Sep 2021
1 answer
472 views

I have a columns.Select() in my kendo grid which shows checkboxes to select all the rows if I check the checkbox in the header. I need to override the behavior of this control to select only certain fields based on the values of another column.

Is there any way I can bind this any event and get it to work? I tried using jquery using the class I added, but I was not able to get the event to fire. Please suggest.

@(Html.Kendo().Grid<WMP.Models.Home.WorkFlowApprovalViewModel>()
            .Name("gridApprovals")
            .Columns(columns =>
            {

                    columns.Select().MinResizableWidth(5).HtmlAttributes(new { @class = "cmddestroy" });


                columns.Bound(c => c.PersonId).Filterable(ftb => ftb.Multi(true).Search(true));
                columns.Bound(c => c.UserName).Filterable(ftb => ftb.Multi(true).Search(true));
                columns.Bound(c => c.UserEmail).Filterable(ftb => ftb.Multi(true).Search(true));

}

                                                   
Eyup
Telerik team
 answered on 03 Sep 2021
1 answer
742 views

I have a DropDownList and users are annoyed that whilst the data is loaded it says "No data found." when in fact, the data hasn't been loaded yet - I found this config item:

https://docs.telerik.com/kendo-ui/api/javascript/ui/dropdownlist/configuration/messages.nodata

How do I make one message appear whilst the data source is loading, and another message once the data has loaded (and in fact, there was no data found)

Ivan Danchev
Telerik team
 answered on 02 Sep 2021
0 answers
147 views

Hi team

I have Kendo MVC Grid.I Implemented In cell batch Edit grid with Dropdownlist column.This grid will not have Create,Delete Operation. only Update operation is availble.I need to Defualt my dropdown  to Particular Value if Cell value have 0.Dropdown will have Values as 5 to 10.And i want to Make 5 as Defualt value if Cell value is 0.

Can any one help on this please

sai
Top achievements
Rank 1
 asked on 02 Sep 2021
Narrow your results
Selected tags
Tags
+? more
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Will
Top achievements
Rank 2
Iron
Motti
Top achievements
Rank 1
Iron
Hester
Top achievements
Rank 1
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Thomas
Top achievements
Rank 2
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?