Telerik Forums
Kendo UI for jQuery Forum
7 answers
5.1K+ views
Hello,

Is there a way to restrict kendo combobox being edited manually but only allow the user to select from the dropdown values. If yes would you give an example in razor please?

I also want to allow the user to edit to a valid date in a kendo datepicker but not any other text. Is that possible?

Thanks
Floris
Top achievements
Rank 1
Iron
 answered on 07 Nov 2020
1 answer
4.8K+ views
I have a kendo grid with a column that has a row template that is a checkbox. When it is selected, it marks that row as selected so that I can operate on a subset of the rows selected by the user.

I wish to place a checkbox in the column header that will check or uncheck every row in the grid.

I have tried adding a headerTemplate with a checkbox but I do not know how to cause it to select all rows.

Also, for some reason the checkbox in the header does not get checked when I click it, instead when I click it, it appears to try to sort the grid (the asc/desc arrows appear on the header cell). I've tried adding `filterable: false` but this still happens.

My grid is below. The column in question is `select_all`

    <div id="PatrolRecords"
            data-filterable='{ "mode": "row" }'
            data-role='grid'
            data-sortable='true'
            data-detail-template='patrolDetailTemplate'
            data-detail-init='detailInit'
            data-bind='source: reportData, events: {excelExport: excelExportHandler}'
            data-bound='onDataBound'
            data-pageable='{ "pageSize": 10 }'
            data-toolbar='[{ template: kendo.template($("#toolbarTemplate").html()) }]'
            data-excel='{ "fileName": "Patrols.xlsx", "allPages": "true" }'
            data-columns='[
                {
                    field: "address",
                    title: "Address",
                    template: kendo.template($("#addressTemplate").html()),
                    filterable: { cell: { operator: "contains" } }
                },
                {
                    field: "end_date_seconds",
                    title: "Date & Time",
                    template: kendo.template($("#dateTemplate").html()),
                    filterable: false
                },
                {
                    field: "patrolled_by",
                    title: "Patrolled By",
                    filterable: { cell: { operator: "contains" } }
                },
                {
                    field: "select_all",
                    width: 35,
                    headerTemplate: "<input type=\"checkbox\" id=\"chkAll\" />",
                    template: "<input type=\"checkbox\" class=\"check_row\" />",
                    filterable: false
                }
            ]'>
        </div>
Kamaraj
Top achievements
Rank 1
Veteran
 answered on 07 Nov 2020
2 answers
157 views

 

I checked the documentation for the API and am utilizing the open method

However when opening the calendar popup this way the keyboard navigation no longer works.  The only way to select a date seems to be via mouse click.

 

The issue is re-creatable on the demo example below

https://docs.telerik.com/kendo-ui/api/javascript/ui/datepicker/methods/open

I have found I can programatically set a kind of focus using the code

setTimeout(function () {
                 var ev = $.Event("keydown");
                   ev.keyCode = 39;
                      $("#FromDate").trigger(ev);
}, 100);

 

But after this the keyboard navigation is still not active.

Is there a way to make this work?

 

 

james
Top achievements
Rank 1
 answered on 06 Nov 2020
6 answers
194 views

I have added some fields with caption names like this:
location: { caption: "Butik" }
but the problem is that its not used for grouping
it seems like a bug to me, is there way around it? 

https://stackoverflow.com/questions/31749074/kendo-pivotgrid-translation-bug

Tsvetomir
Telerik team
 answered on 06 Nov 2020
1 answer
129 views

While re-ordering columns in Chrome 100% zoom.   Telerik v 2020.2.512.0   Javascript error: Cannot read property '_owner' of null     at Telerik.Web.UI.GridColumn._onMouseUpHandler 

is failing on line 45152  if (d != null && this._canDragDrop && !j._owner._isResize) Telerik.Web.UI.WebResource

Any ideas?  Of where to look for the cause. 

 

Tsvetomir
Telerik team
 answered on 06 Nov 2020
1 answer
122 views

     Hi team,

 

The edit zone of the view html dialog does not fit the width of that dialog and cannot be resized.

 

Best regards.

 

Laurent.

Aleksandar
Telerik team
 answered on 06 Nov 2020
1 answer
1.4K+ views

Hello, 

 

Is it possible to add a textbox dinamically, by clicking a button?

I have the following code, and I need to add a textbox, just like the one I already have when click the "Add Button"

 

01.<!DOCTYPE html>
02.<html>
03.<head>
04.    <meta charset="utf-8"/>
05.    <title>Kendo UI Snippet</title>
06. 
08. 
09.    <script src="https://code.jquery.com/jquery-1.12.4.min.js"></script>
12.</head>
13.<body>
14.   
15.    <div>
16.      <input id="textbox" style="width: 100%;" />
17.      <input type="button" id="add" value="Add TextBox" class="k-button"/>
18.    </div>
19.    <script>             
20.                $(document).ready(function () {
21.           $("#textbox").kendoTextBox({
22.               placeholder: "email@email.com.br",
23.                label: {
24.                    content: "Email",
25.                    floating: true
26.                }
27.             });
28.          })
29.    </script>
30.</body>
31.</html>

Stoyan
Telerik team
 answered on 05 Nov 2020
1 answer
285 views

Hi

Do have facility for print(Export to PDF) Gantt chart in to PDF with multiple pages.

One of our client want this feature.

 

Regards

mamachan

Ivan Danchev
Telerik team
 answered on 04 Nov 2020
1 answer
196 views

How to truncate chart title if text is too long also once text is truncate show full text on mouse over or show in tooltips.

https://dojo.telerik.com/IRaJuJiH

Tsvetomir
Telerik team
 answered on 04 Nov 2020
2 answers
173 views

Hello,

 

after upgrading my Gantt chart to release 2020 R3 SP1 I noticed a significant performance drop in the chart to the point of it not being snappy enough to give to end users. I have made a simple repro at https://dojo.telerik.com/OjOCEjIm/4 (I hope this links to my custom edit, if not the code is down below to copy paste into a Dojo window). It is a simple Gantt chart where I add 50 summary tasks and 50 child tasks for those. 

 

When running the chart in the dojo under 2020 R2 SP1 the chart loads fast and clicking open a summary task has an almost imperceptible delay. But when switching to 2020 R3 or R3 SP1 releases from the dropdown in the top left, the same chart takes multiple seconds to load and opening of a summary task takes about 1-2 seconds.

 

I'm in a situation where the data to be displayed in the Gantt sometimes is in the order of 35-50*35-50 tasks. Are there any performance hints I might employ to make the R3 release usable as I would like to use for example the columnMenu option that I believe is only available in R3? Also any and all performance hints are welcome.

 

If the link up doesn't link to the custom Dojo, here is the code to copypaste:

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <title>Kendo UI Snippet</title>
 
    
 
    <script src="https://code.jquery.com/jquery-1.12.3.min.js"></script>
</head>
<body>
   
    <div id="gantt"></div>
    <script type="text/javascript">
      var gantt;
 
      $(function StartingPoint() {
    var ganttDatasource;
 
      this.ganttDatasource = new kendo.data.GanttDataSource();
         
        gantt = new kendo.ui.Gantt($("#gantt"),
                                   $.extend({
          columns: [
            { field: "id", title: "ID", sortable: true, editable: false, width: 70 },
            { field: "title", title: "Title", sortable: true, editable: true, width: 100 },
            { field: "start", title: "Start", sortable: true, editable: true, format: "{0:MM/dd/yyyy HH:mm}", width: 100 },
            { field: "end", title: "End", sortable: true, editable: true, format: "{0:MM/dd/yyyy HH:mm}", width: 100 }
            
          ],
          views: [
            "year"
          ],
          listWidth: 300,
          height:800,
          dataSource: this.ganttDatasource
        }, {}));
 
let tasks=[];
         
    // random tasks
     
        for (p=1;p<50;p++) {
                tasks.push({id:"p"+p,parentId:null,  title:"task", start:new Date(2020, p+1, 1),end:new Date(2020, p+2, 1), summary:true});
 
                for (var t=0;t<50;t++) {       
      tasks.push({id:"p"+p+"t"+t,parentId:"p"+p,  title:"task", start:new Date(2020, t+1, 1),end:new Date(2020, t+2, 1)});
       
       
        }
    }
 
        this.ganttDatasource.data(tasks);
 
        gantt.refresh();
    });
    </script>
</body>
</html>
Rami
Top achievements
Rank 1
Veteran
 answered on 04 Nov 2020
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
Dialog
Chat
DateRangePicker
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
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?