Telerik Forums
UI for ASP.NET MVC Forum
3 answers
333 views
In my Kendo grid, I am displaying checkboxes for users to select rows. Once the rows are selected, the user clicks on a button to view the selected records in another view for additional processing. How do I pass the selected rows' ids to the controller/another view?
Suresh
Top achievements
Rank 1
 answered on 07 Jan 2015
1 answer
996 views
I'm using the Kendo MVC grid and an Ajax.BeginForm request to query data for rendering in a partial view (that has the grid object). It all works fine, but I'm wondering how to go about letting the user know that a long operation is occurring when the ajax request is started. I haven't been able to find anything specific to Kendo MVC that doesn't use mobile application popups. Are there any good examples of Kendo MVC/Ajax/async and some sort of loading indicator? Thanks!

...k
Dimo
Telerik team
 answered on 07 Jan 2015
1 answer
122 views
Hi there,

I am just transforming my pure ASP.net Application into an angular SPA.

The kendo widgets are defined with MVC wrappers and I use small javascripts i.e for 
--> .Events(e => e.DataBound("onDataBound")) or 
--> .Read(read => read.Action("Index", "Contact").Data("updateGrid")

However the scripts do not work when angular loads the partial. (updateGrid is not defined)

What is the best approach to reference a javascript from within a mvc defined Grid? Can I hand in an angular controller method somehow?


Thank you very much!
Alexander Valchev
Telerik team
 answered on 07 Jan 2015
1 answer
208 views
I have a form using various Kendo widgets (i.e. TextBoxFor, AutocompleteFor, etc) to capture data for my process.  When I submit the form and try to load view with an empty version of my viewmodel, much of the content in the view is from my previous screen when I use both TextBoxFor and AutoCompleteFor.  However, if I switch these to MaskedTextBoxFor everything seems to work fine.  

For example, I have an Address view capturing an address with John Doe 123 Main, NYC, NY and click submit to send it to my controller.  In my controller I create a new Address object and pass it back to the Address View.  When the View loads and I am using TextBoxFor or AutoCompleteFor, the contents to the boxes is still John Doe 123 Main, NYC, NY.  However if I change any of the fields to MaskedTextBoxFor, the correct data is displayed in the field.

Sorry if this is confusing, but I am not sure how to describe this so it makes the most sense.
Georgi Krustev
Telerik team
 answered on 07 Jan 2015
1 answer
139 views
I'm currently struggling with the MultiSelect inside a Grid Editor Template in that the posted model has too many strings.

This is from my editor template...

@(Html.Kendo().MultiSelectFor(model => model.messages)
      .Name("key_messages") // With or without makes no difference
      .Placeholder("Select Key Messages")
      .BindTo((System.String[])ViewData["key_messages"]))

My string array, "key_messages" is defined in my controller

string[] key_messages = { "work ethic", "efficiency", "fiscal" };
ViewData["messages"] = key_messages;

In my model

public string[] key_messages { get; set; } //I've also tried using List<string> with same results

Using fiddler, I can see that the posted data contains way too many objects.  For example, if I select "work ethic" and "efficiency", I get the following.

key_messages[0]
key_messages[1] work ethic
key_messages[2] work ethic
key_messages[3] efficiency

To make matters worse, if I save this, then attempt to remove one of the "work ethics", I get this (even though only two selections remain)...

key_messages[0]
key_messages[1] work ethic
key_messages[2] work ethic
key_messages[3] efficiency
key_messages[4] work ethic
key_messages[5] efficiency

I'm assuming that this is some type of serialization problems but I've not been able to put my finger on the problem.  

Please help.

Georgi Krustev
Telerik team
 answered on 06 Jan 2015
1 answer
576 views
This is my code i use this code to add control in telerik control but its showing a error.


@(Html.Kendo().Window()
    .Name("window")
    .Draggable()
    .Title("Window Popup")
    .Width(600)
    .Height(200)
    .Visible(false)
    .Content(@<text>
        @Html.Label("Select Image")
        @Html.Kendo().Upload();
        </text>)
)
Dimo
Telerik team
 answered on 05 Jan 2015
3 answers
122 views
hello
in the Help Document for the Grid

http://www.telerik.com/help/aspnet-mvc/telerik-ui-components-grid-client-api-and-events.html#insertRow


the insertRow function is described


insertRow object example

var grid = $("#Grid").data("tGrid");
var product = { ProductName: "KeyBoard", UnitPrice: 53.20};
grid.insertRow(product);



But in the current version of Kendo Ui MVC there is no function
insertRow()


Why? Is there an replacement?


Regards and best wishes for the new year
Atanas Korchev
Telerik team
 answered on 05 Jan 2015
1 answer
112 views
I'm trying to extend telerik kendo grid with some custom functionality (buttons). It relies on row selection. Is it possible to subscribe to selection change event for all grids on page, including those which are not rendered yet? It should work in analogy to the on() jquery method.

What I want to achieve is basically enabling/disabling some grid buttons in toolbar based on whether a row is selected or not. So maybe I'm going into wrong direction from the start and it can be done easier?
Georgi Krustev
Telerik team
 answered on 05 Jan 2015
3 answers
273 views
hi, these are  my codes for infinite scrolling but its not working .
i posted the code please check and i also debug the code but my action also  not running ..

i provided the code below please check...



@(Html.Kendo().MobileView()
       .Title("Scroll down to load")       
       .Content(obj =>          
            Html.Kendo().MobileListView<TelerikMvcApp5.ShoppingModel.PRODUCT_IMAGE>()
                .Name("endless-scrolling")
                .TemplateId("template")
                .EndlessScroll(true)                    
                .ScrollTreshold(30)
                .DataSource(dataSource =>
                    dataSource
                        .Read("Scroll", "Image")
                        .PageSize(20)                            
                )
        )   
)

<script type="text/x-kendo-tmpl" id="template">
    <div class="product">
        <img src="#=IMAGENAME#" alt="image" class="pullImage"/>
   
    </div>
</script>

<style scoped>
    .product h3 {
        font-size: 1.3em;
        font-weight: normal;
        line-height: 1.4em;
        margin: 0;
        padding: .5em 0 0;
        overflow: hidden;
        white-space: nowrap;
        text-overflow: ellipsis;
    }
    .product p {
        font-size: 1em;
        margin: 0;
        padding: .3em 0 0;
    }
    .pullImage {
        width: 64px;
        height: 64px;
        border-radius: 3px;
        float: left;
        margin-right: 1em;
    }
</style>


This is my action with controller

public class ImageController : Controller
    {
        ShoppingEntities db = new ShoppingEntities();
        //
        // GET: /Image/
        public ActionResult Index()
        {
            return View();
        }


[AcceptVerbs(HttpVerbs.Post)]

    public ActionResultScroll([DataSourceRequest] DataSourceRequest request)
        {

            var list = db.PRODUCT_IMAGE.ToList();
            return Json(list.ToDataSourceResult(request));

        }
    }
Petyo
Telerik team
 answered on 03 Jan 2015
0 answers
70 views
Hello,
         I want to add a control in telerik control so please give a proper solution. 
         This is my code

         @(Html.Kendo().Window()
    .Name("window")
    .Draggable()
    .Title("Window Popup")
    .Width(600)
    .Height(200)
    .Visible(false)
    .Content(@<text>
        @Html.Label("Select Image")
        @Html.Kendo().Upload();
        </text>)

I used this code to add control but its showing error message.
)
Shakil
Top achievements
Rank 1
 asked on 03 Jan 2015
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
Upload
ComboBox
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
MultiColumnComboBox
Dialog
DropDownTree
Checkbox
Slider
Switch
Notification
ListView (Mobile)
Pager
Accessibility
ColorPicker
DateRangePicker
Wizard
Security
Styling
Chat
MediaPlayer
TileLayout
DateInput
Drawer
SplitView
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Template
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Licensing
Rating
ScrollView
ButtonGroup
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
DropDownButton
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
+? more
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Edmond
Top achievements
Rank 1
Iron
fabrizio
Top achievements
Rank 2
Iron
Veteran
RobMarz
Top achievements
Rank 2
Iron
Fakhrul
Top achievements
Rank 1
Iron
Tejas
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?