Telerik Forums
UI for ASP.NET MVC Forum
2 answers
117 views
Hi,

I want to edit and display in a kendo window a time property (format HH:mm). 
I started with the Time editor and with a DateTime attribute, but the value to be biended is not displayed in the form.
How can we fix it ?
Apparently the Timepicker supports a TimeSpan value, but Javascript doesn't support Timespan (json serialization problems).
ex : @Html.EditorFor(m => m.StartTime, "Time")

Thanks for your help
Stephane
Top achievements
Rank 1
 answered on 08 Jul 2015
1 answer
379 views
I'm trying to add a custom button on a TreeList Toolbar.   I can see that .Toolbar (t=>t.Custom().Text("My Action")) is exactly what I'm looking for, however what is not obvious is how to add the action.   For the Grid, it would be .Toolbar(t=>t.Custom().Action("Action", "Controller").Text("My Action").   Why does TreeList have similiar behaviour?
Dimiter Madjarov
Telerik team
 answered on 08 Jul 2015
1 answer
172 views
I have been able to successfully build an integrate a Custom Editor Template for the events in the scheduler. However, There are certain fields in the Model being edited that I only want to display- the user should not be able to edit the values. I also want to include a button inside of the Custom Editor that links to another area of the web app based off of one of these readonly Model properties. However, I have been having issues getting these readonly properties to properly bind to the view... I have tried Html.DisplayFor, and this is not binding correctly. How can I properly bind and access the values for Model properties inside of a Custom Editor while keeping the values read-only?
Vladimir Iliev
Telerik team
 answered on 08 Jul 2015
2 answers
106 views

I have a scheduler setup with filters. I have ServerOperation(false) so that my filters can be changed without doing a reload. Lastly, I have the read defined like Read(read => read.Action("Read", "Home").Data("getDateRanges")). The getDateRanges function returns an object with start and end dates.

 When my page loads, all works fine. I can turn on and off filters and watch appointments come and go. No network requests are made for this. When I move from a week view to a day view and back to a week view no network requests happen. All is well. Now, I change weeks, or move to a monthly view. I can only see appointments already loaded. This should have triggered a new Read event but does not.

What can I do to fix this? If I turn ServerOperation to true, then it reloads always even when changing from a week to a day mode.

Georgi Krustev
Telerik team
 answered on 08 Jul 2015
2 answers
95 views

Hi,

I try to use this tree list; i need to expand a complete parent-multiple children in the tree. So:

- child deep in the hierarchy is known to my code and can be found in the tree list

- via code, the complete tree needs to be expanded to expand the child itself and all its parents

The demos only seem to work programmatically expanding nodes which are already displayed, but in this case the child nodes can be hidden. Is there a way to do this? Thanks in advance!

Best regards,

Ruud

Ruud
Top achievements
Rank 1
 answered on 08 Jul 2015
2 answers
960 views

I am trying to add percentages as labels to my Kendo bar chart - I have got this working for Pie Charts fine but the same code isn't working for bar charts.  For the pie charts I use the .Template property of the label, and the "percentage" property is inherently available (I've not defined it in my model I'm binding to anywhere). This is what I am using for the series for my pie chart (working) :-

 .Series(series => series
        .Pie(model => model.Share, model => model.SiteSurveyed.ToString(), model => model.Color)
        .Padding(0)
        .Labels(labels => labels
            .Visible(true)
            .Template("#= category # - #= value # (#= kendo.format('{0:P}', percentage)#)")
            .Align(ChartPieLabelsAlign.Column)
            .Position(ChartPieLabelsPosition.Center)
        )
    )

And this is what I am using for my bar charts (not working - the UI just puts undefined in the label) :-

   .Series(series => series
        .Bar(d => d.Share, d => d.Color)
        .Labels(labels => labels
            .Visible(true)
            .Template("#= value # (#= kendo.format('{0:P}', percentage)#)")
            .Position(ChartBarLabelsPosition.Center)
        )
    )

Please can you advise how I can make this work.

Thanks, Mark

Mark
Top achievements
Rank 1
 answered on 08 Jul 2015
8 answers
397 views
Hi. I'm looking for an example in Razor like the Grid Toolbar demo found here: http://demos.kendoui.com/web/grid/toolbar-template.html. I've put together the basics and it is working but a more complete example would be great. The docs found here: http://docs.kendoui.com/api/web/grid#toolbar-array also do not provide help in getting the Razor syntax correct.
Vladimir Iliev
Telerik team
 answered on 08 Jul 2015
1 answer
283 views

Hello,

i run into a problem about conditional binding properties. I want certain properties only writeable on creating an entity, but not on editing. Generally i can fix it on server side by just adding code to check it or just not bind some properties. But how i can solve this on client side? Let's take the following example:

Data model ->

public classs MyDataModel
{
    [ScaffoldColumn(false)]
    public long Id { get; set; }
 
    [Required(AllowEmptyStrings = false)]
    [StringLength(255)]
    [DisplayName("Title")]
    public string Title { get; set; }
 
    [Required(AllowEmptyStrings = false)]
    [StringLength(255)]
    [DisplayName("Description")]
    public string Description { get; set; }
 
    [Required(AllowEmptyStrings = false)]
    [DisplayName("Type")]
    [DefaultValue(1)]​
    public int TypeOfSomething { get; set; }
}

 

So "TypeOfSomething" should be only writeable on creating the entity. On later editing it should be read only. There is an interesting approach in this comment http://www.codethinked.com/aspnet-mvc-think-before-you-bind/comment-page-1#comment-3933, but i don't see any way to realize this with the Telerik Grid.
Maybe one of you guys have an idea or some hints for achieving this on client side with the Telerik Grid.

 thanks & regards

Alexander Popov
Telerik team
 answered on 08 Jul 2015
1 answer
162 views

Hi,

Is it possible that Kendo UI to detect Microsoft Edge browser? It seem like currently it is detect as Webkit.

Sample of Microsoft Edge user agent string from https://msdn.microsoft.com/en-us/library/hh869301%28v=vs.85%29.aspx:

Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Safari/537.36 Edge/12.0

Thanks.

Kiril Nikolov
Telerik team
 answered on 08 Jul 2015
1 answer
133 views

Hi,

Is it scrollable tab must set the width to tabstrip and cannot auto detect? How to make it work as responsive, automatically scroll when browser width smaller than tabstrip width and hide when exceed tabstrip width.

 

Thanks.

Dimo
Telerik team
 answered on 07 Jul 2015
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?