Telerik Forums
Kendo UI for jQuery Forum
1 answer
336 views

Hello,

I need use export excel With ProxyURL 

i got error when I click on the button export to excel 

Samlpe Dojo

thanks

Lance | Senior Manager Technical Support
Telerik team
 answered on 03 Oct 2022
1 answer
566 views

I need to display a table for the autocomplete (like the multicombobox).

I have already done this on a previous version of telerik with the code:

                              .HeaderTemplate("<div class=\"k-grid-header\" style=\"padding-right: 17px;\">" +
                                                "<div class=\"k-grid-header-wrap\">" +
                                                   "<table>" +
                                                      "<colgroup>" +
                                                         "<col>" +
                                                         "<col>" +
                                                         "<col>" +
                                                         "<col>" +
                                                      "</colgroup>" +
                                                      "<tbody>" +
                                                         "<tr>" +
                                                            "<th class=\"k-header\">P1</th>" +
                                                            "<th class=\"k-header\">P2</th>" +
                                                            "<th class=\"k-header\">P3</th>" +
                                                            "<th class=\"k-header\">P4</th>" +
                                                         "</tr>" +
                                                      "</tbody>" +
                                                   "</table>" +
                                                "</div>" +
                                             "</div>")
                              .Template("<span class=\"k-cell\">#: data.P1#</span>" +
                                        "<span class=\"k-cell\">#: data.P2#</span>" +
                                        "<span class=\"k-cell\">#: data.P3#</span>" +
                                        "<span class=\"k-cell\">#: data.P4#</span>")
but this one does not work anymore in the current version. I do not remember from where I took this example and I cannot find an example anymore. Is this because the multicombobox was created?
Eyup
Telerik team
 answered on 03 Oct 2022
1 answer
825 views

Grid :-

.Columns(columns =>
{
    columns.Bound(x => x.Role).Title("<b>Project OBS Role</b>").Width("30%").Filterable(true).
    HeaderHtmlAttributes(new { style="text-align:center;"}).HeaderHtmlAttributes(new { style = "text-align:center;vertical-align:middle;" });

    columns.Bound(x => x.UserId).Title("<b>Approver</b>").Width("40%").EditorTemplateName("GridGroupPeoplePicker").
   ====>  EditorViewData(new { SecurityGroup = "#=SecurityGroup#" }).Filterable(true).HeaderHtmlAttributes(new { style = "text-align:center;vertical-                     align:middle;"       }).HtmlAttributes(new { style = "text-align:left;" });

    columns.Bound(x => x.Delay).Title("<b>Delay<b>").Width("20%").Filterable(true).
    HeaderHtmlAttributes(new { style = "text-align:center;vertical-align:middle;" }).HtmlAttributes(new { style = "text-align:left;" });

    columns.Command(command => { command.Edit().Text(" ").CancelText(" ").UpdateText(" ");}).Width("10%").
    HtmlAttributes(new { style = "text-align:center;" });
})

 

Editor Template :-

@model string
@{
    string Groups = ViewData["SecurityGroup"] as string;
}
<input type="hidden" id="hdn@(Html.IdForModel())" data-bind="value: @(Html.IdForModel())" disabled="disabled" />
<input type="hidden" id="GroupName_@(Html.IdForModel())" data-bind="value: @(Groups)" disabled="disabled" />
<script>
    function GetGroups_@(Html.IdForModel())(e) {
        debugger;
        var filterInput = $('#hdn@(Html.IdForModel())').val();
        var Groups = $('#GroupName_@(Html.IdForModel())').val();
        return { PickerFilter: filterInput, GroupNames: '@Groups', IsUsersByGroup: 'false' };
    }
</script>
@(Html.Kendo().DropDownListFor(m => m)
        .DataValueField("Value")
        .DataTextField("Text")
        .Filter(FilterType.Contains)
        .MinLength(3)
        .AutoBind(false)
        .DataSource(ds =>
        {
            ds.ServerFiltering(true).Read(r => r.Action("GetUserByGroups", "Common").Data("GetGroups_" + Html.IdForModel()));
        })
)
Aleksandar
Telerik team
 answered on 30 Sep 2022
1 answer
227 views

We have need of a way to show an editor when user clicks on a plain HTML element. There will be more fields than visible when the div goes into edit mode. Same way we use a clientTemplate in our KendoGrids.

I picture,

  1. listening for click on a div
  2. showing an already-instantiated kendoWindow
  3. populate it with the edit values we want
  4. Prefer to position window exactly over the element being edited
  5. allowing the user to edit
  6. on enter key or tab out of the last field, transfer the changes back to the div
  7. hide the kendoWindow ready for re-use

If no examples exist, it would be nice to hear from moderators on why this couldn't be done. Or, better, how nicely it could work :-)

I've done something like this about 7 years ago and it worked well, but I no longer have access to that code-base.

Bob Graham

Neli
Telerik team
 answered on 30 Sep 2022
1 answer
114 views

Hello,

 

I want the tooltip to remain open when trying to click on the content of tooltip. Below is my code.

---Grid

 @(Html.Kendo().Grid<AgeInformation>()
    .Name("AgeInformationGrid")
    .Columns(columns =>
    {
        columns.Bound(p => p.FundAge).Title("Agency").ClientTemplate("#=FundAge.FedAgeDesc#").Sortable(false).Width(175).HeaderHtmlAttributes(new { @class = "FundAgeClass" });

  })

    .ToolBar(toolbar => toolbar.Create())
    .Editable(editable => editable.Mode(GridEditMode.InLine))
    .Pageable()
    .Sortable()
    .Scrollable()
    .HtmlAttributes(new { style = "height:500px;" })
    .DataSource(dataSource => dataSource
        .Ajax()
        .AutoSync(false)
        .Batch(false)
        .PageSize(20)
        .ServerOperation(false)
        .Events(events => events.Error("errorHandler"))
        .Events(events => events.RequestEnd("onAgeInformationRequestEnd"))
        .Model(model => {
            model.Id(p => p.AgeInformationId);
            model.Field(p => p.AgeInformationId).Editable(false);
           model.Field(p => p.FundAge).DefaultValue(new FedAgency());
        })
        .Create(update => update.Action("AddAgeInformation", "Coversheet").Type(HttpVerbs.Post))
        .Read(read => read.Action("GetAgeInformation", "Coversheet").Type(HttpVerbs.Get))
        .Update(update => update.Action("EditAgeInformation", "Coversheet").Type(HttpVerbs.Post))
        .Destroy(update => update.Action("DeleteAgeInformation", "Coversheet").Type(HttpVerbs.Post))
    )
    //.Events(events => events.Edit("onAgeInformationEdit"))
    )    

 

 function ToolTipsForAgency() {

 

        $(".FundAgeClass").append("&nbsp;<i class='far fa-question-circle'></i>");       

$(".FundAgeClass").attr("data-html", "true");
       $(".k-dropdown, .FundAgeClass").find('i').attr("title", "More information can be found on this link <a href='https://google.com' title='test add link'>link on content</a>");
     

}

 

Any help is appreciated

Aleksandar
Telerik team
 answered on 30 Sep 2022
1 answer
141 views

When I tried to export excel, the data format changed.

For example, the data that is seen in the browser looks like this: 01:01:30 

However, checking the excel after export, the time shows like this: 3690, which is seconds.

How can I get the same format in the browser and in excel?

Thanks.

{
			field: "cn_busy_grp",
			title: "통화시간",
			columns :[{
				field: "ts_busy_times",
				title: "총통화시간",
				template: '#=convertSecondsToString(ts_busy_times, "hms")#',
				footerTemplate: '#=convertSecondsToString(sum, "hms")#',
				groupFooterTemplate: '#=convertSecondsToString(sum, "hms")#',
				width: "80px"
			},


Nikolay
Telerik team
 answered on 29 Sep 2022
0 answers
112 views

I am trying to select any step and when selecting it load information in a grid, but with the select event it only works in the step before or after the active one.

 var stepper = $("#stepper").kendoStepper({
                steps: Objson,
                select: function(e) {
                    console.log("i found");
                    e.preventDefault();}              }).getKendoStepper();
Oscar
Top achievements
Rank 1
 asked on 28 Sep 2022
1 answer
253 views

Hi,

I'm tryign to dynamically change the tagMode of a kendo.ui.DropDownTree as a user selects more or less items but the control does not refresh/rerender

 

Below is a sample of the code I have tried...

 var ddt = $(id).data('kendoDropDownTree');
        var maxSelectedItemsDisplayedInSingleTagMode = 3;
        let selectedValues = ddt.value();
        let currentTagMode = ddt.options.tagMode;
        let newTagMode = currentTagMode;

        newTagMode = selectedValues.length <= maxSelectedItemsDisplayedInSingleTagMode ? "multiple" : "single";
        if (newTagMode != currentTagMode) {
            ddt.value([])
            ddt.setOptions({
                tagMode: newTagMode
            });
            ddt.value(selectedValues);
        }

Something similar does work for the kendo.ui.MultiSelect but I cannot get it to play ball for kendo.ui.DropDownTree

 

Thanks

Neli
Telerik team
 answered on 28 Sep 2022
1 answer
557 views

I get content as HTML encoded and would like to render this content as HTML in a grid row column using a template.

template: window.kendo.template($("#title").html())

<script id="title" type="text/x-kendo-template">
  <strong>#:title#</strong>
  <div>#:content#</div>
</script>

Have tried many (all) combinations of #:content#, #=content#, encoded: false, kendo.htmlEncode...

Please see the screenshot.

What am I doing wrong?

/Morten

 

Nikolay
Telerik team
 updated answer on 27 Sep 2022
1 answer
246 views

Hello ,

I'm using below code for date validation

 sheetForNPD.range("O2:O100").validation({
        dataType: "date",
        showButton: true,
        comparerType: "between",
        from: "DATEVALUE(\"1/1/1900\")",
        to: "DATEVALUE(\"1/1/2050\")",
        allowNulls: true,
        type: "reject",
        titleTemplate: "Start Date validation error",
        messageTemplate: "Start Date should be between 1899 and 2050 year."
    }).format('MM-dd-yy');

 

But i need if user enter in these format then also acceptable 

    • Slashes

      • M/D/YY

      • M/D/YYYY

      • MM/DD/YY

      • MM/DD/YYYY

    • Dashes

      • M-D-YY

      • M-D-YYYY

      • MM-DD-YY

      • MM-DD-YYYY

    • Dots

      • M.D.YY

      • M.D.YYYY

      • MM.DD.YY

      • MM.DD.YYYY

    Is it possible in kendo spreadsheet can i validate these format for single column ?

Neli
Telerik team
 answered on 27 Sep 2022
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?