Telerik Forums
Kendo UI for jQuery Forum
1 answer
703 views
I have the following values in my in my razor div tag:

 

 

<div class="countdownKendoGrid" data-bind="kendoGrid: { data: $parent.RandomList, rowTemplate: ​'rl-row-template',​columns: [{ field: 'COL1', title: 'COL1', width: '50%' }, { field: 'COL2', title: 'COL2', width: '50%' }], filter: [{ field: ​'COL1', operator: 'eq', value: 'AB1234' }]}​"></div>

My questions, since I'm rather new at this, are:
1). Why would just the row where COL1 equals to AB1234 not be the only one that appears?
2).  could I substitute "value: 'AB1234'" to be a property in my ViewModel?  ie: value: $parent.MyBindableValue

J

 

​​​​​​​​​​​​​​​

 

Alexander Valchev
Telerik team
 answered on 23 Apr 2014
5 answers
494 views
Hi, 

I am using trail version, i just want to know is there any API in your framework which allows me to print Grid and charts? 


Thanks,
Amar
Dimo
Telerik team
 answered on 23 Apr 2014
1 answer
115 views
.cshtml

<script type="text/x-kendo-tmpl" id="flashetTemplate">
        <div class="flashetItem" id="flashetContainer">
        <h5>${Name.substring(0,10)}</h5>
            <span class="flashetDesc">${Description.substring(0,150)}</span>
            <table class="flashetsTable">
                <tr>
                    <td class="flashetStats"><img src="/Content/Images/ThumbsUp.png" title="Likes" /></td>
                    <td class="flashetStats"><img src="/Content/Images/Comments.png" title="Comments" /></td>
                    <td class="flashetStats"><img src="/Content/Images/Shared.png" title="Shared" /></td>
                    <td class="flashetStats"><img src="/Content/Images/relevance.ico" title="Relevance" /></td>
                    <td class="flashetStats"><img src="/Content/images/folder.png" title="Resources" /></td>
                </tr>
             
            </table>
    </div>

@(Html.Kendo().ListView<Flashet>() //The listview will be initially bound to the Model which is the Products table
          .Name("flashetView") //The name of the listview is mandatory. It specifies the "id" attribute of the widget.
          .TagName("div") //The tag name of the listview is mandatory. It specifies the element which wraps all listview items.
          .ClientTemplateId("flashetTemplate") // This template will be used for rendering the listview items.
          .DataSource(dataSource => {
                                        dataSource.Read(read => read.Action("GetFlashetsData", "Home"));
                                        dataSource.PageSize(5);
          })
          .Pageable())

Jquery
$(document).ready(function () {
    //alert("document loaded...");
    $("#flashetContainer").click(function (event) {
        alert('div clicked....');
    });
});

Why does the click event not work when we click on the div. What would the dynamic id be <div class="flashetItem" id="flashetContainer"> , since based on the GetFlashetsData resultset there would be multiple div blocks generated
Dimiter Madjarov
Telerik team
 answered on 23 Apr 2014
5 answers
164 views
Currently my web application is in flex ui , We are trying to migrate to kendo ui. But im facing problem in binding the grid with restful services . 
I used ajax call and was able to bind it to IE of a lower version. But the code still doesnt work with other browsers and also IE of higher version.


Atanas Korchev
Telerik team
 answered on 23 Apr 2014
1 answer
193 views
I am receiving the error "Maximum call stack size exceeded" while trying to bind Signalr data to the KendoUI grid (v2014.1 416).

Here is my current code:

var epConnection = $.hubConnection();
var hub = epConnection.createHubProxy("EventsPendingHub");
var hubStart = epConnection.start();
 
$('#tblEventsPending').kendoGrid({
    sortable: true,
    columns: [
        { field: "EventNum" },
        { field: "Area" },
        { field: "Zone" },
        { field: "Priority" },
        { field: "Type" },
        { field: "TIQ" },
        { field: "Location" },
        { field: "Apt"}
    ],
    dataSource: {
        type: "signalr",
        autoSync: true,
        schema: {
            model: {
                id: "EventNum",
                fields: {
                    "EventNum": { type: "string" },
                    "Area": { type: "string" },
                    "Zone": { type: "string" },
                    "Priority": { type: "string" },
                    "Type": { type: "string" },
                    "TIQ": { type: "string" },
                    "Location": { type: "string" },
                    "Apt": {type: "string"}
                }
            }
        },
        sort: [
            { field: "Priority", dir: "desc"},
            { field: "TIQ", dir: "desc"}
        ],
        transport: {
            signalr: {
                promise: hubStart,
                hub: hub,
                server: {
                    read: "read",
                    update: "update",
                    destroy: "destroy",
                    create: "create"
                },
                client: {
                    read: "read",
                    update: "update",
                    destroy: "destroy",
                    create: "create"
                }
            }
        }
    }
});

I'm looking for setup suggestions to fix this problem or known workarounds.

Thank you.
Vladimir Iliev
Telerik team
 answered on 23 Apr 2014
1 answer
2.4K+ views
Hi,

Kendo UI Grid is reloading the data with previously selected page number. If  I moved to 10th page of the Grid and then i am reloading the Grid with recent data. Grid data  is still showing the 10th page  instead of 1'st page. How can i reload the grid with focus on  first page. 

{  
var grid = $("#grid").data("kendoGrid");  
grid.dataSource.page(1);
}
If i placed the above code before reloading, it's taking time to reload the grid.
If i placed the above code after reloading, it's hitting the sever twice.

Please suggest on this.

Thanks,
Raj Yennam
Vladimir Iliev
Telerik team
 answered on 23 Apr 2014
4 answers
927 views
Hello,

Im using a beta version of kendoui.

Is there a way to limit the characters shown in a kendo grid cell?
I've tried using text-overflow but won't work.

thank you. :)
Masaab
Top achievements
Rank 1
 answered on 23 Apr 2014
2 answers
318 views
is there a way to get the list of uploaded files added to a datasource.
Here is my attempt, my alert box returns the appropriate data, but for some reason the grid is not displaying the returned data.
$("#files").kendoUpload({
                    async: {
                        saveUrl: "upload.aspx",
                        autoUpload: true,
                        batch: false
                    },
                    files: files,
                    upload: function (e) {
                        filecount = filecount + 1;
                        $.map(e.files, function (file) {
                            var info = file.name;
                            var filesize = file.size
                            var upGrid = $('#upfilelist').data("kendoGrid");
                            var dataSources = UFSource;
                            var newrecord = { ufid: compups, FileName: info, FileSize: filesize };
                            //alert(compups +'_'+ filename + '_' + filesize);
                            dataSources.insert(newrecord);
                            upGrid.dataSource = dataSources;
                        });
                    },
                    complete: function (e) {
                        //filecount = 0;
                        compups = compups + 1
                                                                        
                        document.getElementById("FileCount").innerText = 'Files Uploaded: ' + filecount;
                        $(".k-upload-files.k-reset").find("li").parent().remove();
                    },
                    showFileList: true
                     
                });









Troy Clemons
Top achievements
Rank 1
 answered on 22 Apr 2014
1 answer
180 views
I've been trying to solve this problem for a while with no luck. I'm trying to get some odata with the following code:

var dataSource = new kendo.data.DataSource({
    dataType: "odata",
    transport: {
        read: {
            url: "http://localhost:8080/odata/SDA/TEIID_TEST",
            beforeSend: function(req){
               req.setRequestHeader('Authorization','Basic dXNlcjp1c2Vy');
            }
        }
    }
 });
dataSource.read();  

Which seems like the right thing to do, given the other posts I've read on this subject. But when I actually look at what's going on using Tamper in Firefox, it sends an OPTIONS request. On the other hand, when I repeat the code used above WITHOUT the beforeSend part, it sends a GET request - but still no luck of course, because I can't authorize. 

How do I get around it? (Here's a StackOverflow post I made for reference, complete with screenshots.)


Kiril Nikolov
Telerik team
 answered on 22 Apr 2014
3 answers
649 views
Hi, I'm having a bit of trouble getting a multi select to pass the values back to the controller.
Here's what I have currently tried:

In my model:
[UIHint("abcEditor")] <- name of partial view containing the multiselect (used on grid popup window)
 public string[] abc { get; set; }

In my partial view:
@using Kendo.Mvc.UI
@(Html.Kendo().MultiSelect()
    .Name("abc") // Name of the widget matches in the model
    .DataValueField("ID")  <- PersonModel (Contains - ID, FullName, Email, etc..)
    .DataTextField("FullName")  
    .BindTo((System.Collections.IEnumerable)ViewData["def"]) // A list of PersonModels which is populated in the controller
    .Placeholder("Add")  
)

Controller: (Received Values)
- model.abc     {string[2]} string[]
    [0] null string
    [1] null string

ID is a Guid but if I try Guid[] I get the same result. 
I can select things fine, and it returns an array with the correct number selected, but the values in the array are null?
If anyone can point me in the right direction it would be a great help!
Thanks
Petur Subev
Telerik team
 answered on 22 Apr 2014
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
DatePicker
Spreadsheet
Upload
ListView (Mobile)
ComboBox
TabStrip
MultiSelect
AutoComplete
ListView
Menu
Templates
Gantt
Validation
TreeList
Diagram
NumericTextBox
Splitter
PanelBar
Application
Map
Drag and Drop
ToolTip
Calendar
PivotGrid
ScrollView (Mobile)
Toolbar
TabStrip (Mobile)
Slider
Button (Mobile)
Filter
SPA
Drawing API
Drawer (Mobile)
Globalization
LinearGauge
Sortable
ModalView
Hierarchical Data Source
Button
FileManager
MaskedTextBox
View
Form
NavBar
Notification
Switch (Mobile)
SplitView
ListBox
DropDownTree
PDFViewer
Sparkline
ActionSheet
TileLayout
PopOver (Mobile)
TreeMap
ButtonGroup
ColorPicker
Pager
Styling
MultiColumnComboBox
Chat
DateRangePicker
Dialog
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Effects
Accessibility
PivotGridV2
ScrollView
BulletChart
Licensing
QRCode
ResponsivePanel
Switch
Wizard
CheckBoxGroup
TextArea
Barcode
Breadcrumb
Collapsible
Localization
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
TimePicker
BottomNavigation
Ripple
SkeletonContainer
Avatar
Circular ProgressBar
FlatColorPicker
SplitButton
Signature
Chip
ChipList
VS Code Extension
AIPrompt
PropertyGrid
Sankey
Chart Wizard
OTP Input
SpeechToTextButton
InlineAIPrompt
StockChart
ContextMenu
DateTimePicker
RadialGauge
ArcGauge
AICodingAssistant
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?