Telerik Forums
Kendo UI for jQuery Forum
1 answer
277 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
38 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
314 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
117 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
410 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
206 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
476 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
334 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
1 answer
79 views
I'm experiencing a bizarre issue only in IE9 where I have a tab strip, within the tabstrip is a simple grid with row detail, having fixed columns exceeding the width of the grid thus showing the horizontal scrollbar. When I mouse over the rows or select a row, whitespace is being added to the bottom of the grid. Then once you move the mouse outside the grid, the whitespace goes away and the grid returns to its original size.

If I remove the row detail and do not make the rows or cells selectable, this behavior does not occur.

I need to have row detail, fixed columns and horizontal scrolling because in my app, I can display up to 20 or so columns based on the user's preference.

Here is the jsfiddle using the latest Kendo release and jquery 1.9.1. I also saw this in the previous release as well.
http://jsfiddle.net/Fh29p/

Most of my users are IE8 and are moving to IE9 so this issue needs to be resolved.

Any help is appreciated.
Dimo
Telerik team
 answered on 19 Apr 2013
2 answers
418 views
I have a strange artifact happening only in Safari on osx 10.8.3 where when I click in an input text field, which I have setup as a search box on the grid, the color of the font in the grid and other items on the page including a panelBar changes color.  I also see this happening in the listView when selecting the edit button.  On another page I have several panels with edit templates.  When I click on one of the edit buttons, the correct panel updates with the edit template but again, all of the text on the page as well as the panelBar changes color.  I'm assuming with the edit button situation it is because the edit template has a text field that is receiving focus, and this is somehow triggering a change in the css.

I am not seeing this result in firefox on osx or chrome in win7.

Any ideas how to resolve this or is there a workaround by forcing a css value for the text items being adjusted on text field focus?

Thanks,
Andrew

After some more exploring I found out that if I close an open section in the panelBar then the colors will return to their normal value.  If I select a section in the panelBar then the colors change again....

Could be a problem with the panelBar rather than the text field focus...
Andrew
Top achievements
Rank 1
 answered on 19 Apr 2013
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
Chat
MultiColumnComboBox
Dialog
DateRangePicker
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Accessibility
Effects
PivotGridV2
ScrollView
Switch
BulletChart
Licensing
QRCode
ResponsivePanel
TextArea
Wizard
CheckBoxGroup
Localization
Barcode
Breadcrumb
Collapsible
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
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?