Telerik Forums
Kendo UI for jQuery Forum
7 answers
1.9K+ views
I notice the following 'features' after attaching a change event to a grid.
 1) The change event fires even when an already selected row is clicked on.
 2) The change event fires when clicking on an anchor or a button element in a grid's row.

Any work-around suggestion for the grid to not fire the change event in the above cases is appreciated.

Thank you in advance.
loi
Top achievements
Rank 1
 answered on 19 Apr 2013
3 answers
74 views
Hi Guys!

It's great to see the addition of the three new widgets to the ThemeBuilder page but i noticed when trying to use the AutoComplete and MultiSelect by typing to bring up the results list it doesn't happen because there is a javascript error being thrown. I'm trying to get a look-and-feel using real life functionality of Kendo UI suite of widgets under different themes.

Could we have this full functionality of AutoComplete and MultiSelect widgets enabled in ThemeBuilder page ? 

Cheers!
Kamen Bundev
Telerik team
 answered on 19 Apr 2013
1 answer
256 views
Hello,

Is it possible to use the horizontal menu with split button instead of regular button to be touch friendly? So i can have a link for each item and a button to open the submenu. Maybe the tree view is better for this task?

I find a way to do it for the first level of the menu with the markup below but i didn't find how to do it with the sub menus
<style scoped>
     #menu > .k-item.empty-split {
        width: 16px;
    }
 
    #menu > .k-item.empty-split > .k-link {
        padding-left: 0;
        padding-right: 0;
    }
</style>   
 
 <ul id="menu">
        <li>Blog
        </li>
        <li class="empty-split">
            <span class="k-link">
                <span class="k-icon k-i-arrow-s"></span>
            </span>
            <ul>
                <li>
                    <div id="template" style="padding: 10px;">
                        <h2>Around the Globe</h2>
                        <ol>
                            <li>United States</li>
                            <li>Europe</li>
                            <li>Canada</li>
                            <li>Australia</li>
                        </ol>
                        <img src="../../content/web/menu/map.png" alt="Stores Around the Globe" />
                        <button class="k-button">See full list</button>
                    </div>
                </li>
            </ul>
        </li>
    </ul>

<script type="text/javascript">
        $(function () {
            $("#menu").kendoMenu({
                openOnClick: true
            });
        });
    </script>
Dimo
Telerik team
 answered on 19 Apr 2013
0 answers
27 views
How to using custom footer temple while binding field?It say studentId undefined,but studentIdis my table property
My codes like this:

columns.Bound(p => p.studentId);
columns.Bound(p => p.Point)
ClientGroupFooterTemplate("<div>average: #=kendo.toString(getPointby(studentId),'n0')#</div><div>max: #= max #</div><div>min: #= min #</div>");
ABC
Top achievements
Rank 1
 asked on 19 Apr 2013
1 answer
290 views
Hello

When I right click on telerik grid without selecting a row, I should be able to see my own context menu.

Which event supports this? I used Onload in the following way.

My Grid is defined in the following way:

@{Html.Telerik().Grid(Model)
    .Name("AccountVisitStatusGrid") 
    .DataKeys(keys => keys.Add("AccountStatusID"))
    .DataBinding(dataBinding => dataBinding.Ajax().Select("_GetAccountVisitStatusCodes", "AccountVisitStatus"))
    .ClientEvents(events => events
                         .OnRowDataBound("Grid_onRowDataBound")
                         .OnDataBound("AcctVisitStatusGridBound")
                         .OnRowSelected("AcctVisitStatusGridRowSelected")
                         .OnError("AcctVisitStatusGridErrored")
.OnLoad("onload")
                         )                
    .Columns(columns =>
    {
        columns.Bound(o => o.Code).Title("Code").Width(100);
        columns.Bound(o => o.Name).Title("Name").Width(150);
        columns.Bound(o => o.Description).Title("Description").Width(150);
        columns.Bound(o => o.PASAccountStatus).Title("PAS Status").Width(150);
        columns.Bound(o => o.IsActive).ReadOnly().Title("Active").ClientTemplate("<input type='checkbox' name='ckActive' <#= IsActive? checked='checked' : '' #> onclick='return false'  />").Width(60);
        columns.Bound(o => o.IsAccount).ReadOnly().Title("Account Status").ClientTemplate("<input type='checkbox' name='ckAccount'  <#= IsAccount? checked='checked' : '' #> onclick='return false' />").Width(120);
        columns.Bound(o => o.IsVisit).ReadOnly().Title("Visit Status").ClientTemplate("<input type='checkbox' name='ckVisit' <#= IsVisit? checked='checked' : '' #> onclick='return false' />");
    })
    .Selectable()
    .Scrollable(c => c.Height("450px"))
    //.Pageable(paging => paging.PageSize(20).Style(GridPagerStyles.NextPreviousAndNumeric).Position(GridPagerPosition.Bottom))
    .Sortable()
    .Filterable()
    .Groupable()
    .Resizable(resizing => resizing.Columns(true))
    .Render();
}

Before, Context menu was only displayed when selected and do right click:
code:

function AcctVisitStatusGridRowSelected(e) {
       // debugger;
        if (!IsEditingDisabled('#btnEditAcctVisitStatus', 'btnEditDisabled')) {
            hideContextMenu(lastAcctVisitStatusDataContextMenu);
            lastAcctVisitStatusDataContextMenu = $(e.row).contextMenu('AcctVisitStatusDataContextMenu',
        {
            menuStyle:
                        {
                            width: 'auto'
                        },
            bindings:
                        {
                            'MenuNewAcctVisitStatus': function (t) {
                                 //debugger;
                                openDialog('N');
                            },
                            'MenuEditAcctVisitStatus': function (t) {
                                // debugger;
                                openDialog('E');
                            }
                        }
        });
        }
    }

Now to enable it just by , right click on grid, how to show up the context menu?????

I used this:


    function onLoad() {
         //debugger;
        $('tr', this).live('contextmenu', function (e) {
       // prevent the browser context menu from showing
       e.preventDefault();
       var $tr = $(this);
      if (!IsEditingDisabled('#btnEditAcctVisitStatus', 'btnEditDisabled')) {
            hideContextMenu(lastAcctVisitStatusDataContextMenu);
      lastAcctVisitStatusDataContextMenu = $(tr).contextMenu('AcctVisitStatusDataContextMenu',
        {
            menuStyle:
                        {
                            width: 'auto'
                        },
            bindings:
                        {
                            'MenuNewAcctVisitStatus': function (t) {
                              // debugger;
                                openDialog('N');
                            },
                            'MenuEditAcctVisitStatus': function (t) {
                                 //debugger;
                                openDialog('E');
                            }
                        }
        });
        }
   });
    }
}

I am not able to display the context menu?? How to solve this? 
For the above case where i just want to display context menu on right click on grid.
Daniel
Telerik team
 answered on 19 Apr 2013
1 answer
103 views
Hi,

Is there a way to distinguish the actions in the grid's databinding event or datasource's change event?

I want to listen for the group changing event to limit the maximum number grouping the user can do to 1.

Thanks
Dimiter Madjarov
Telerik team
 answered on 19 Apr 2013
5 answers
342 views
Hi,

Would it be possible to have a demo of Leaflet for Kendo UI mobile?

http://leaflet.cloudmade.com/examples/mobile.html

I suggest, the first page is listview and second page is the Leaflet map.

Thanks.


Petyo
Telerik team
 answered on 19 Apr 2013
1 answer
177 views
How I can use the "aggregates" in an listview? . If possible, how would I? 

I can see that in a grid itself can by the FooterTemplate property but the listview does not have that property.
 Thanks.
Iliana Dyankova
Telerik team
 answered on 19 Apr 2013
1 answer
406 views
I have a button at top that I wire up to do a filter reset.  I show that button whenever a filter is applied.  However in the columnMenu filter clear, it does clear the filtering of the data, but I need it to hide that button IF there are no more filters.  I am overriding the filter function with a custom filter

Questions:
1)  Is there a way to tie into the clear event that is fired from filterMenu to update certain UI elements?
2) Is there a way to identify if ANY filter is on a grid since the filter function loops through column by column and I want to know if ANY filter is applied?

Thanks.

-John-
Dimiter Madjarov
Telerik team
 answered on 19 Apr 2013
1 answer
306 views
How to use custom content to show the grid's tooltip? I want to show the tooltio ofcoloumn 2 and coloumn 3 ,and the content is  a span which id called spanid or div which is called divid?
               

    var tooltip = $("#Grid").kendoTooltip({
            filter: "td",
            width: 120,
            position: "top",
            content: value
        }).data("kendoTooltip");

I try to write this,but it seems wrong.

    var tooltip = $("#Grid").kendoTooltip({
            filter: "td[3n]||td[2n]",
            width: 120,
            position: "top",
            content: divid.html()
        }).data("kendoTooltip");
Alexander Valchev
Telerik team
 answered on 19 Apr 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?