Telerik Forums
Kendo UI for jQuery Forum
2 answers
602 views
I've got some code which checks if a page has unsaved changes which is using the hasChanges() method of the Kendo dataSource to detect changes made within a grid:
var changed = self.data("kendoGrid").dataSource.hasChanges();

However, for the grid on one page this is failing because the isNew() method is missing from the data items within the dataSource.  If I inspect the dataSource.data() items all of the items are present, but whereas the items on my other pages include a "dirty" field and an "isNew()" method the ones for this page do not.  As far as I can tell there are no substantial differences between the pages.  The one that works does have a couple of aggregates and a change event handler included in the dataSource which the failing one doesn't but I don't see how that would affect this.

Here is the div for the grid from the page that fails:
                <div id="CentersGrid" data-bind="kendoGrid: 
    {
        data: ReportingCenters, 
        widget: centersGrid, 
        dataSource: {
            batch: true, 
            sort: { field: 'Number', dir: 'asc' } ,
        }, 
        scrollable: false,
        pageable: { pageSize: 15, input: true, numeric: false },
        editable: true, 
        sortable: true, 
        navigatable: true,
        columns: [ 
            { field: 'id', hidden: true } ,
            { field: 'Number', width: '20%' } , 
            { field: 'Description', width: '60%' } ,
            { command: [ {name: 'destroy'} ] }
        ],
        toolbar: ['create'],
        dataBound: function(e) { 
            $('#CentersGrid tbody tr .k-grid-delete').each(function() {
                var currentItem = $('#CentersGrid').data('kendoGrid').dataItem($(this).closest('tr'));
                if (currentItem.CanDelete == false) { $(this).remove(); }
            }) 
        }
    }">

The items that seem to be missing from each data item are: dirty, defaults, fields and isNew().
Brian
Top achievements
Rank 1
 answered on 14 May 2013
2 answers
682 views

If I write any text even it is single word, entire Text is wrapped with <p> tags which is giving empty space (margin) in SSRS report. 
Telerik Editor Control has option to disable this behavior with FixEnclosingP Content Filter.

Is there any configuration in Kendo Editor like FixEnclosingP in Telerik Editor Control?


Alex Gyoshev
Telerik team
 answered on 14 May 2013
1 answer
116 views
I'm adding some routes on demand, and have a need to issue a navigate to the current url fragment so that my new route can be processed. I noticed that calling router.navigate(location.hash) does not work because you have smarts to shortcut the action if the route has not changed.

I implemented the following fix, but wanted to share so you can consider adding support for this in the future:
window.kendo.history.current = "/";
router.navigate(location.hash);
Thanks,
Gary
Petyo
Telerik team
 answered on 14 May 2013
1 answer
324 views
http://demos.kendoui.com/web/grid/editing.html

Is there a way to automatically select (highlight) the content of the cell when the cell has been clicked for editing?
Dimiter Madjarov
Telerik team
 answered on 14 May 2013
1 answer
97 views
I was wondering if it were possible to use the "Window" UI widget for multiple list items.

For example, lets say I had a list of companies with reach having a link to "more details" and that more details linked opened a "Window" for each description. These company lists would be created dynamically so the number of listing will vary. 

<ul>
<li>
Company A
<span class="more_detail">More Details</span>
<div class="window">Company A is Great</div>
</li>
<li>
Company B
<span class="more_detail">More Details</span>
<div class="window">Company A is Great</div>
</li>
<li>
Company C
<span class="more_detail">More Details</span>
<div class="window">Company A is Great</div>
</li>
</ul>

Dimo
Telerik team
 answered on 14 May 2013
5 answers
155 views
Hi,

I am having Issue on Ipad on using the editor. 

When I write a very long line without any space or break.

example:
mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm

This line will flow over the editor.

On PC (non-ipad) the editor automatically has a horizontal scroll-bar, but not on Ipad.

Does anyone ever encounter this problem. Did I missed anything in the setting.

The was I set up the editor is pretty straight forward.
$('#some-textarea').kendoEditor({ tools: ["bold", "italic"] });

Thanks in advance,
Hubert


Dimo
Telerik team
 answered on 14 May 2013
2 answers
46 views
Hello,

Here is my scenario:

I have a Mobile Application with a DropDownList and a ColumnChart which displays the selected values from the DropDownList.
When trying to register the kendoMobileSwipeEvent on the KendoChartWrapper i get sideeffects on my DropDownList, so that i'm not allowed to change the selected DropDownList item anymore. The same happens when i change the DropDownList. Then swiping doesn't work anymore.

My question is, where is the right place to register the swipe gesture, so that the user will be able to swipe on the chart to change the chart and the corresponding DropDownList?

Thanks for your help!
Regards,
Vera

Vera
Top achievements
Rank 1
 answered on 14 May 2013
1 answer
187 views
I'm using the Kendo UI Web v2012.3.1114 javascript library. I have multiple instances of the Kendo Editor on my page in table rows that can be reordered on the page. My issue is that if I move one of the rows, the Kendo Editor appears to clear it's value and then stops responding to clicks or key presses.

My guess was that the events were unbound when the editor was moved withing the DOM. Looking through the documentation, I found the .refresh() method (http://docs.kendoui.com/api/web/editor#methods-refresh) which seems to be just what I'm looking for. However, when I try to use this method, I get the error "editor.refresh is not a function." I know I'm accessing the editor properly because the .paste() and .value() functions work fine.

Was the .refresh() function implemented in a later version?
Dimiter Madjarov
Telerik team
 answered on 14 May 2013
4 answers
177 views
hi i am new to kendo Ui i am having trouble in viewing the data in list view although the data is coming to the page ( i have checked it by viewing the source code of the page). Please Help me.
here is View code

@{
    ViewBag.Title = "ListView";
}

        <link href="../../Content/Kendo/kendo.common.min.css" rel="stylesheet" type="text/css" />
        <link href="../../Content/Kendo/kendo.black.min.css" rel="stylesheet" type="text/css" />
        <script src="../../Scripts/jquery-1.7.1.min.js" type="text/javascript"></script>
        <script src="../../Scripts/Kendo/kendo.all.min.js" type="text/javascript"></script>
        <script src="../../Scripts/Kendo/kendo.aspnetmvc.min.js" type="text/javascript"></script>

<h2>ListView</h2>

@(Html.Kendo().ListView(ViewBag.myList).Name("myLV").ClientTemplateId("template").TagName("div").Pageable()
        .HtmlAttributes(new { style = "width:400px;Height:400px;background-color:white;" })
 )


and this is my Controller

 public ActionResult ListView()
        {
            List<KendoModel> myList = new List<KendoModel>();
            for (int i = 1; i <= 100; i++)
                myList.Add(new KendoModel { ProductId = "PID" + i, ProductName = "name" + i, BrandName = "Brand" + i, Price = "Brand" + i });

            ViewBag.myList = myList;
            return View(myList);
        }

and i am attaching a file that shows the output of the code -
Akshay
Top achievements
Rank 1
 answered on 14 May 2013
5 answers
451 views
I have a view with multi a tags with a data-role set to "button".  When scrolling through the view, if i first press on a button and try to scroll the page will scroll but then redirect to the next, which I don't want to happen.  How do i make it so that the button redirects only when the button is tapped and won't redirect if I scroll though the view.

Thanks.
Petyo
Telerik team
 answered on 14 May 2013
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?