Telerik Forums
UI for ASP.NET MVC Forum
1 answer
150 views
I try to use this feature on Dropdownlist but unsuccessful. Any one can provide me a working example besides casading demo one.
Georgi Krustev
Telerik team
 answered on 24 Jan 2013
1 answer
89 views
Hello,
if i have in razor this dropdownlist
@(Html.Kendo().DropDownList()
          .Name("category")
          .OptionLabel("Select a product...")
          .DataTextField("ProductName")
          .DataValueField("ProductID")
          .HtmlAttributes(new { style = "width:200px" })
          .DataSource(source => source.Read("ProductListData", "Controls"))
          .Events(ev => ev.Change("change"))
      
                                        
)

how can i use in the same view, the value of the dropdownlist using razor syntax?
i was looking for something like @Html.Kendo().DropDownList("category").Value()...

Regards,
Daniel

P.S:i think i put first this same post also to Web UI\DropDownList,please excuse me.
Petur Subev
Telerik team
 answered on 24 Jan 2013
4 answers
165 views
Hello,

I have a problem with select tag in latest version of Kendo UI (asp.net MVC Q3 2012).

The options could not be selected if I put select options in a model popup

My select options content:
<select name="country" id="country">
  <option value="AU">AU</option>
  <option value="US">US</option>
  <option value="CN">CN</option>
</select>
It was worked in previous version.

Thanks
 
Justin
Top achievements
Rank 1
 answered on 23 Jan 2013
9 answers
1.1K+ views
I am trying to use a NumericTextBox with a nullable decimal. When the numeric text box is left blank, the default "The field <field name> must be a number" message appears.

How can I submit the data with an empty NumericTextBox to pass a null value to my controller?

Thanks!
Jon
Top achievements
Rank 1
 answered on 23 Jan 2013
2 answers
298 views
Currently the grid edit/delete is showing a button with text along with the mouse over effect, what is the best way to replace these button with an images?  The reason is we see that these button takes too much space and would like to replace it with a smaller image so more data can be shown.  TIA.
Sang
Top achievements
Rank 1
 answered on 23 Jan 2013
6 answers
85 views
Hi,

I'm having a problem with paging where the whole data set is return each turn rather than just the records that are due to appear on that page of the grid.

If I connect straight to the model e.g.

var model = new Context();

var reqassess = model.ReqAssesses;

return reqassess;


Then the query will select the top 30 records etc

But in our projects we tend to have a service layer and repositories
Controller:

public ActionResult Products_Read([DataSourceRequest] DataSourceRequest request)
{
            return Json(GetRequests().ToDataSourceResult(request), JsonRequestBehavior.AllowGet);
}

GetRequests method:

var reqassess = reqAssessService.GetReqAssess();
return reqassess;


Service layer:

public IEnumerable<ReqAssess> GetReqAssess()

{

 return _repository.GetReqAssess();

}

Repository

public IEnumerable<ReqAssess> GetReqAssess()

{      
return _context.ReqAssesses.Where(r => r.CompId == "TEST").ToList();
}

When I do it this way it returns the whole dataset everytime, which causes significant performance problems. Are you able to help me with this at all?

Thanks

Ben
Top achievements
Rank 1
 answered on 23 Jan 2013
2 answers
175 views
I'm trying to install Kendo UI MVC server wrappers on an existing MVC project.

I added a reference to my project (pointing to the dll) and I placed the entry in my web.config file. (all of the js and css files are also there)

My views still cannot find the Html.Kendo() methods.  What else can I be missing?

Thanks
kunapa
Top achievements
Rank 1
 answered on 23 Jan 2013
3 answers
695 views
I'm working in a grid with two fields, one for effective date and the other for retirement date with the retirement date defaulting to DateTime.MaxValue. When I edit the field (inCell mode, if that matters) on the effective date all is well and I get what I'm expecting - MM/dd/yyyy format. However, when I edit the retirement date I get the full date and time format no matter how many different places I specify the format. To test this, I changed the date manually and was able to do so up until December 31st, 2099. After that date, the field went blank. Has anybody else noticed this? Ideas for a workaround other than adding a checkbox for the max date in the template?
Vladimir Iliev
Telerik team
 answered on 23 Jan 2013
2 answers
276 views
Can you nest Grid controls inside a tab strip?  Is so, is there an example?
AWL
Top achievements
Rank 1
 answered on 23 Jan 2013
4 answers
115 views
Hello,

I m using VS2012 and I m working on a MVC 4 project with the trial version of Kendo.I've managed to implement a simple grid and got some basic functionality.
My controller has these 2 methods

private static IEnumerable<MemberViewModel> GetMembers()
      {
          var context = new EntityContext();
          return context.Members.Select(mem => new MemberViewModel
          {
              MemberId=mem.MemberId,
              Name=mem.FirstName,
              SurName = mem.LastName
           
          });
          
        
      }

public ActionResult Members_Read([DataSourceRequest] DataSourceRequest request)
       {
           return Json(GetMembers().ToDataSourceResult(request), JsonRequestBehavior.AllowGet);
       }
And in my view i have this header

<header>

    <link href="~/Styles/kendo.common.min.css" rel="stylesheet" />
    <link href="~/Styles/kendo.default.min.css" rel="stylesheet" />
    <script src="~/Scripts/jquery-1.9.0.min.js"></script>
    <script src="~/Scripts/kendo.all.min.js"></script>
    <script src="~/Scripts/kendo.aspnetmvc.min.js"></script>

</header>
and the grid code is 
(Html.Kendo().Grid(Model)
      .Name("Grid")
      .DataSource(dataSource => dataSource
                                    .Ajax()
                                    .ServerOperation(false)
                                    .Read(read => read.Action("Members_Read", "Home").Type(HttpVerbs.Get)))
                                     
                                     .Pageable()
                                     .Selectable()
                                     .Sortable()
 
      )
As i said grid is showing the results and pagination.But a)Selectable does not work neither in Chrome-Firefox
 b)Sortable is always giving me a json result from server side.I cannot enable client sorting besides i wrote my code exactly the same
as kendo mvc examples. c)ServerOperation(false) still does not disables server side sorting.d)I ve added to web.config this line
 <modules runAllManagedModulesForAllRequests="true" />  but again no client side sorting.

Any ideas on what is wrong with the above?
Thanx in advance

Missing User
 answered on 22 Jan 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Jay
Top achievements
Rank 3
Bronze
Iron
Iron
yw
Top achievements
Rank 2
Iron
Iron
Stefan
Top achievements
Rank 2
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Bohdan
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?