Telerik Forums
Kendo UI for jQuery Forum
1 answer
81 views
Is there a possibility of achieving this kind of functionality on mobile using a list view inside a drawer? Example below.

http://demos.kendoui.com/mobile/splitview/index.html#/
Petyo
Telerik team
 answered on 07 Aug 2013
3 answers
171 views
Can I define my own range and labels in the Linear Gauge?

Controller:
public ActionResult LinearGauge()
{
List<gaugeSetting> gaugeModel = new List<gaugeSetting>();

gaugeModel.Add(new gaugeSetting { From = 1, To = 2, Color = "#000099", Label = "Requirements" });
gaugeModel.Add(new gaugeSetting { From = 2, To = 3, Color = "#009900", Label = "Design" });
gaugeModel.Add(new gaugeSetting { From = 3, To = 4, Color = "#ff0000", Label = "Development" });

return View(gaugeModel)
}

View:

@(Html.Kendo().LinearGauge()
.Name("gauge")
.Pointer(pointer => pointer
.Value(2)
.Shape(GaugeLinearPointerShape.Arrow)
)
.Scale(scale => scale
.Vertical(false)
.Labels(l =>
{
//Get the Labels from the Model
})
.MajorUnit(1)
.MinorUnit(1)
.Max(7)
.Ranges(ranges =>
{
//Get the Ranges from the Model
}
)
)
.HtmlAttributes(new { style = "width:500px;" })
)
Iliana Dyankova
Telerik team
 answered on 07 Aug 2013
1 answer
675 views
I have a column that binds to an MVC Model.

When the value is negative it should be displayed in red. 

How is that done?

 
columns.Bound(e => e.UnrealizedGainLoss)
       .Title("Unrealized Gain /<br> Loss ($)")
       .HeaderHtmlAttributes(new {title = "Market Value and Book Value."})
       .Format("{0:N}")
       .ClientFooterTemplate("<div class=aright>#= kendo.format('{0:N}', sum) #</div>")
       .HeaderHtmlAttributes(new {@class = "aright"})
       .HtmlAttributes(new {@class = "aright"});
Dimo
Telerik team
 answered on 07 Aug 2013
3 answers
212 views
With the recent updates, some of my old code has become broken. The relevant part here relating to using a DataSource to pass information back to an Mvc3 controller. Specifically, the object I am using has a field that contains an array which used to get passed to parameterMap as "Array[5]", and is now getting passed as o.extend.init[5]. This isn't recognized when I attempt to send the data to my controller action. 

Currently, I am using a workaround in parameter map where I read the values from the "o.extend.init[5]" into a plain array, and assign it to the same field in the object before converting it to JSON to be returned. Is there a cleaner solution built into Kendo that will just return that field as an array when I get the object from the DataSource?

Thanks.
Cody
Top achievements
Rank 1
 answered on 07 Aug 2013
2 answers
75 views
Kendo Validator toggles class "k-invalid" only on  inputs that are validated. So I can manage the appearence of simple inputs. But how I can style whole widget?
Widget markup usually consists of several inputs and wrappers.  And validation styling should be applied to one of that wrappers. For example to ".k-widget .k-numeric-wrap" for NumericTextBox and so on. But validator does not have appropriate settings or extension points (some set of events for instance) to do that. At least I have not found that neither in docs nor in source code.  It's not complex for me to modify source code of the validator to add this feature. But I don't want to merge my modification into following versions.

Is there some approach to solve problem?
Anton
Top achievements
Rank 1
 answered on 07 Aug 2013
6 answers
241 views
hi i want to select date  and time with validation from date to todate can any one post sample datetime picker code plz...
Suma
Top achievements
Rank 1
 answered on 07 Aug 2013
3 answers
241 views
Hi,

I get the error "Kendo.Mvc.Infrastructure.Implementation.FilterParserException: Unterminated string" when I try to filter using the character "&"

Here is the URL of the query: 
localhost/Documents?Grid-sort=WorkOrder.ShortTitle-asc&Grid-page=1&Grid-pageSize=10&Grid-group=&Grid-filter=WorkOrder.ShortTitle~contains~'&'


[FilterParserException: Unterminated string]
Kendo.Mvc.Infrastructure.Implementation.FilterLexer.<TryParseString>m__17F(Char character) +164
Kendo.Mvc.Infrastructure.Implementation.FilterLexer.Read(Func`2 predicate, StringBuilder result) +57
Kendo.Mvc.Infrastructure.Implementation.FilterLexer.TryParseString(String& string) +180
Kendo.Mvc.Infrastructure.Implementation.FilterLexer.Tokenize() +155
Kendo.Mvc.Infrastructure.Implementation.FilterParser..ctor(String input) +39
Kendo.Mvc.Infrastructure.FilterDescriptorFactory.Create(String input) +54
Kendo.Mvc.UI.DataSourceRequestModelBinder.BindModel(ControllerContext controllerContext, ModelBindingContext bindingContext) +202
Kendo.Mvc.UI.Grid`1.ProcessDataSource() +187
Kendo.Mvc.UI.Grid`1.WriteHtml(HtmlTextWriter writer) +574
Kendo.Mvc.UI.WidgetBase.ToHtmlString() +86
Kendo.Mvc.UI.Fluent.WidgetBuilderBase`2.ToHtmlString() +22
System.Web.HttpUtility.HtmlEncode(Object value) +38
System.Web.WebPages.WebPageBase.Write(Object value) +75

I am using kendo version 2013.1.514.340

Thanks
Atanas Korchev
Telerik team
 answered on 07 Aug 2013
4 answers
794 views
Hi,

 In my application I am populating a ListView using a service call. I am adding a TextBox and a filter button in the navbar of that page. I have filtered the ListView using the following method.

 function filter(){
        var listView = $("#SubFolderList").data("kendoMobileListView");
        listView.dataSource.filter({ field: "ItemName", operator: "contains", value: SearchValue });
        //here i need the count of the items
 } 

I have a clear filter button near to the filter button, I want to clear the filter on pressing the clear button.

Please help me finding a solution with service call

Thanks,
Amrutha.
Amrutha
Top achievements
Rank 1
 answered on 07 Aug 2013
1 answer
291 views
Do we have any navigation property for Kendo grid Datasource?

Eg:  
@(Html.Kendo().Grid(Model)
.Name("Grid")
.Columns(columns =>
{
columns.Bound(p => p.ProductID).Groupable(false);
columns.Bound(p => p.ProductName);
columns.Bound(p => p.UnitPrice);
columns.Bound(p => p.UnitsInStock);
})
.Groupable()
.Pageable()
.Sortable()
.Scrollable()
.Filterable()
.DataSource(dataSource => dataSource
.Ajax()
.Read(read => read.Action("Data", "API"))
)
)

From the API service, we are getting the actual data enclosed in some other object.

Our entity structure is like

Data [Class]
  1. Error Message [Property]
  2. Employees[Property]
  3. Status [Property]

I want to set grid's data source as the Employees(property) . 

Please help.

Atanas Korchev
Telerik team
 answered on 07 Aug 2013
2 answers
144 views
Multiselect control returns to the controller results in alphabetical order. Is there a possibility that the results are returned in the order of selection. In my case it is a condition of use.

Thank you very much
Damian
Top achievements
Rank 1
 answered on 07 Aug 2013
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?