Telerik Forums
UI for ASP.NET MVC Forum
1 answer
75 views
i use app.navigate('#test') when i input transition to view ,will open view 2 times
if i not put transition no problem but run event onshow 2 times
Kiril Nikolov
Telerik team
 answered on 13 Jun 2014
3 answers
341 views
Hello,

I need some help, please.

I have a mobile drawer, but I want to change the way the button looks depending on if the drawer is showing or not.
Any ideas on how to do this? I am not sure which style property to use for this.

Thanks
Kiril Nikolov
Telerik team
 answered on 12 Jun 2014
3 answers
987 views
I am trying to use ListView using MVC 

 @{Html.Kendo()
           .ListView(Model)
           .Name("cutomers")
           .BindTo(Model);
  }

Where do we specify templates? I do see there's a ClientTemplateId property exposed but not able to find its usage.
Can you please share any sample showing ListView in MVC.

Thanks,
Kuljit
Daniel
Telerik team
 answered on 12 Jun 2014
7 answers
246 views
I'm trying to use the new html5 report viewer using the example given here HTML5 Report Viewer with MVC .

Whenever i try to call the controller class from the example , i get this error:

The IControllerFactory 'CNX.WebUI.Infrastructure.NinjectControllerFactory' did not return a controller for the name 'MenuReport'.

Does Telerik have any tutorials on how to use this new report viewer in conjunction with Ninject?


Stef
Telerik team
 answered on 12 Jun 2014
6 answers
917 views
Hi,

I'm developping an ASP.NET MVC application using Kendo UI v2014.1.415.  Some of the Kendo controls are not rendering properly in Release mode. I check the the css bundle I found the following :
/* Minification failed. Returning unminified contents.
(27,35175): run-time error CSS1030: Expected identifier, found '.'
(27,35182): run-time error CSS1031: Expected selector, found ')'
(27,35182): run-time error CSS1025: Expected comma or open brace, found ')'
*/

Here is the code from my bundle config :

 bundles.Add(new ScriptBundle("~/bundles/jquery").Include(
                        "~/Scripts/jquery-{version}.js"));

            bundles.Add(new ScriptBundle("~/bundles/jqueryval").Include(
                        "~/Scripts/jquery.validate*"));

            // Use the development version of Modernizr to develop with and learn from. Then, when you're
            // ready for production, use the build tool at http://modernizr.com to pick only the tests you need.
            bundles.Add(new ScriptBundle("~/bundles/modernizr").Include(
                        "~/Scripts/modernizr-*"));

            bundles.Add(new ScriptBundle("~/bundles/bootstrap").Include(
                      "~/Scripts/bootstrap.js",
                      "~/Scripts/respond.js"));

            bundles.Add(new StyleBundle("~/Content/css").Include(
                      "~/Content/bootstrap.css",
                      "~/Content/site.css"));

            //Kendo UI - Begin
            const string VersionKendo = "2014.1.415";
            const string KendoScriptFolder = "~/Scripts/kendo/" + VersionKendo + "/";
            const string KendoCssFolder = "~/Content/kendo/" + VersionKendo + "/";

            bundles.Add(new ScriptBundle("~/bundles/kendo").Include(
                KendoScriptFolder + "kendo.all.min.js",
                KendoScriptFolder + "cultures/kendo.culture.en-US.min.js",
                KendoScriptFolder + "cultures/kendo.culture.fr-FR.min.js",
                KendoScriptFolder + "kendo.aspnetmvc.min.js"
                ));

             bundles.Add(new StyleBundle("~/Content/kendo/css").Include(
                KendoCssFolder + "kendo.common.min.css", 
                KendoCssFolder + "kendo.metro.min.css",
                KendoCssFolder + "kendo.default.mobile.min.css"));
            
            // Clear all items from the default ignore list to allow minified CSS and JavaScript files to be included in debug mode
            bundles.IgnoreList.Clear();

            // Add back the default ignore list rules sans the ones which affect minified files and debug mode
            bundles.IgnoreList.Ignore("*.intellisense.js");
            bundles.IgnoreList.Ignore("*-vsdoc.js");
            bundles.IgnoreList.Ignore("*.debug.js", OptimizationMode.WhenEnabled);
            //Kendo UI - End          

            BundleTable.EnableOptimizations = true;

How can I fix this?




Sebastian
Telerik team
 answered on 12 Jun 2014
2 answers
220 views
Hi Guys,

I am using the Combobox and it is giving me a javascript error. I have made sure JQuery is only included once and other Kendo controls are working.

Razor Code
@(Html.Kendo().ComboBox()
                            .Name("Projects")
                            .DataTextField("ProjectName")
                            .DataValueField("ProjectID")
                            .HtmlAttributes(new { style = "width:200px" })
                            .Filter("contains")
                            .AutoBind(false)
                            .MinLength(3)
                            .DataSource(source =>
                            {
                                source.Read(read => { read.Action("GetProject", "VMS"); }).ServerFiltering(true);
                            })) 

Controller Code
public JsonResult GetProject([DataSourceRequest] DataSourceRequest request)
        {
            var model = _db.Project.ToList();
            var result = model.ToDataSourceResult(request, r => new
            {
                ProjectID = r.ID,
                ProjectName = r.Name,
            });
            return Json(result, JsonRequestBehavior.AllowGet);
        }

JSON from fiddler
{"Data":[{"ProjectID":1,"ProjectName":"Project 1"},{"ProjectID":2,"ProjectName":"Project 2"},{"ProjectID":3,"ProjectName":"Project 3"}],"Total":3,"AggregateResults":null,"Errors":null}

Chrome error
Uncaught TypeError: undefined is not a function kendo.all.min.js:11
ct.extend.success kendo.all.min.js:11
b.isFunction.i jquery-1.9.1.js:7223
n.success kendo.all.min.js:11
c jquery-1.9.1.js:7341
p.fireWith jquery-1.9.1.js:7403
k jquery-1.9.1.js:9597
r

Thanks
Andrew





Andrew
Top achievements
Rank 1
 answered on 11 Jun 2014
5 answers
465 views
Hi,

I am using "resizable:true" in Kendo Grid, but only filterable columns can be re-sized. Non-filterable (with "filterable:false") columns can't be re-sized. I have searched it on Kendo forums, but apparently no solution.

Regards
Zaheer
Dimo
Telerik team
 answered on 11 Jun 2014
5 answers
624 views
Hi I have a kendo grid in my partial view.
And I have bind a model as the grid data source. And mention that my grid don't have a Read method. Instead of read method I have use the model.
Here is my view..
@model Project.MVC.Areas.Razor.Models.CustomerListModel

<div id="dvResultGrid">
@(Html.Kendo().Grid<Portal.Application.BoundedContext.ScreenPop.Dtos.Customer>(Model.CustomerList)
.Name("grdWindowResults")

.Columns(columns =>
{
columns.Bound(x => x.Name1).Visible(true);
columns.Bound(x => x.Name2).Visible(true);
columns.Bound(x => x.ContactName);
columns.Bound(x => x.BillingAddress1);
})
.Pageable()
.Sortable(x => x.Enabled(false))
.Scrollable(x => x.Height("auto"))
.Selectable(selectable => selectable.Mode(GridSelectionMode.Single))
.Reorderable(reorder => reorder.Columns(true))
.DataSource(dataSource => dataSource
.Ajax()
.ServerOperation(false)
.PageSize(5)
.Model(model =>
{
model.Id(p => p.CustomerId);

})
)
)
</div>
And what I have to do is, I need to do server-side paging for my grid. How can I do that with out a read method. Is there any option?




Atanas Korchev
Telerik team
 answered on 11 Jun 2014
3 answers
317 views
Hello,
Is it possible to change dynamically the Image (in ImageUrl) in my Tabstip?
@( Html.Kendo().TabStrip()
        .Name("TabStripMaster")
        .Items(parent =>
        {
            parent.Add().Text("Description")
                .Selected(true)
                .ImageUrl("~/Content/Common/Icons/Description.png")
May I use JScript?
Regards,
Bruno
Vladimir Iliev
Telerik team
 answered on 11 Jun 2014
1 answer
497 views
I am using the Kendo.EditorFor() control to display editors as I loop through a List of objects. I have server-side validation in play and when I submit the form, it correctly identifies that the fields are not filled in. However, the appropriate classes are not added to any of the HTML elements that are returned back to the browser, and therefore there is no visual indicator of which editor(s) have not been filled in.

Here's a copy of my HTML:

    @using (Html.BeginForm("SaveSelfAssessment", "Accreditation", FormMethod.Post, new { id = "form", enctype = "multipart/form-data" }))
    {
        @Html.ValidationSummary(false, "The following errors occurred:", new { @class = "error_box" })
    
        <input type="hidden" id="Id" name="Id" value="@Model.Id" />
        <input type="hidden" id="StartingId" name="StartingId" value="@Model.StartingId" />
        
        for (int i=0; i<Model.ApplicationSelfAssessments.Count; i++)
        {
            @Html.HiddenFor(m => m.ApplicationSelfAssessments[i].Id)
            @Html.HiddenFor(m => m.ApplicationSelfAssessments[i].Type)

            <div class="@Model.ApplicationSelfAssessments[i].Type">
            @if (Model.ApplicationSelfAssessments[i].Type == "supplementalinformation")
            {
                <h2>Supplemental Information</h2>
            }
                @Html.Raw(Model.ApplicationSelfAssessments[i].Text)
            </div>
        
            if (Model.ApplicationSelfAssessments[i].Type == "question")
            {
                <div>@(Html.Kendo().EditorFor(m => m.ApplicationSelfAssessments[i].Answer)
                          .Encode(false)
                          .Tools(tools => tools
                                  .Clear()
                                  .Bold()
                                  .Italic()
                                  .Underline()
                                  .InsertUnorderedList()
                                  .InsertOrderedList()
                                  .Indent()
                                  .Outdent()
                            )
                        )
                </div>
            }
        }
        
        <p>
            <input type="button" class="k-button k-button-icontext" value="Previous" onclick="window.location = '@Model.PreviousUrl';" />
            <input type="submit" class="k-button k-button-icontext" value="Next" />
        </p>
    }

And my model contains the following Validate method:

        public IEnumerable<ValidationResult> Validate(ValidationContext validationContext)
        {
            if (Type == SelfAssessmentType.Question.ToString().ToLower() && String.IsNullOrWhiteSpace(Answer))
            {
                yield return new ValidationResult("Answer is required", new [] { "Answer" });
            }
        }

If I turn the editor into a textarea, the input-validation-error class is added to the textarea. Is there a way I can get this to work using the Kendo.EditorFor tool?

Thank you,

Rachael
Rachael
Top achievements
Rank 1
 answered on 10 Jun 2014
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
ComboBox
Upload
MultiSelect
ListView
Window
TabStrip
Menu
Installer and VS Extensions
Spreadsheet
AutoComplete
TreeList
Gantt
PanelBar
NumericTextBox
Filter
ToolTip
Map
Diagram
Button
PivotGrid
Form
ListBox
Splitter
Application
FileManager
Sortable
Calendar
View
MaskedTextBox
PDFViewer
TextBox
Toolbar
Dialog
MultiColumnComboBox
DropDownTree
Checkbox
Slider
Switch
Notification
Accessibility
ListView (Mobile)
Pager
Security
ColorPicker
DateRangePicker
Wizard
Styling
Chat
DateInput
MediaPlayer
TileLayout
Drawer
SplitView
Template
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Licensing
Rating
ScrollView
ButtonGroup
DropDownButton
CheckBoxGroup
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
AIPrompt
PropertyGrid
ActionSheet (Mobile)
BulletGraph
Button (Mobile)
Collapsible
Loader
CircularGauge
SkeletonContainer
Popover
HeatMap
Avatar
ColorGradient
CircularProgressBar
SplitButton
StackLayout
TimeDurationPicker
Chip
ChipList
DockManager
ToggleButton
Sankey
OTPInput
ChartWizard
SpeechToTextButton
InlineAIPrompt
TimePicker
StockChart
RadialGauge
ContextMenu
ArcGauge
AICodingAssistant
SmartPasteButton
PromptBox
SegmentedControl
LLM Kit
+? more
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Tien
Top achievements
Rank 1
Iron
Krasimir
Top achievements
Rank 3
Bronze
Iron
Iron
Cedar
Top achievements
Rank 1
Iron
Emil
Top achievements
Rank 1
Iron
Kyle Watson
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?