Telerik Forums
UI for ASP.NET MVC Forum
1 answer
145 views

     Hello, I am using dotnet MVC 6 (not core) and I have a need to only allow the KendoUI on some pages but not others. I am using the controls on a form built before we bought KendoUI, some forms were pre-built using the dotnet mvc scaffolding tool. Those forms do not need the KendoUI emitters, which normally would not be a problem except that when I run the project I am getting the following error in chrome:

Uncaught ReferenceError: kendo is not defined

And the following code is included for each control on the page:

kendo.syncReady(function(){jQuery("#First_Name").kendoTextBox({"value":"James"});});

I have tried removing the javascript references and that did not work, the code still gets emitted. I know why it is happening, because the javascript files are loaded at the bottom of the page, way after the above script tries to execute. I can't use deferred as I am not using the Kendo helpers on this page. Is there any other way to do this besides moving the kendo controls to the top of the page? And, if I have to move the controls to the top of the page, can I do that without moving the bootstrap and jquery script calls to the top as well (IE., are the kendo scripts dependent on JQuery or Bootstrap to be initialized first)?

Thanks in advance...

Martin
Telerik team
 answered on 08 Feb 2021
3 answers
532 views

Using FileManager in our app, and we are seeing the following exception when trying to create a "New Folder".   We do not see this error with any other operations, and are able to upload, rename, & delete files/folders without issue.   Is this a binding issue with our resulting json (see below)?  The funny thing is that this exception does not occur every time we click the "New Folder" button.  It shows up maybe 75% of the time. 

 

The exception is:

VM8695:3 Uncaught ReferenceError: extension is not defined
    at eval (eval at compile (kendo.all.js:234), <anonymous>:3:164)
    at init.refresh (kendo.all.js:70463)
    at init.proxy (jquery-3.1.1.js:502)
    at init.trigger (kendo.all.js:164)
    at init._process (kendo.all.js:7940)
    at init._change (kendo.all.js:7889)
    at init.proxy (jquery-3.1.1.js:502)
    at init.trigger (kendo.all.js:164)
    at init.splice (kendo.all.js:5008)
    at init.insert (kendo.all.js:7078)

 

 

Our FileManager datasource is a configured like this...

dataSource: {
    schema: kendo.data.schemas.filemanager,
    transport: {
        read: {
            url: "MyController/GetObjects/",
            method: "POST"
        },
        create: {
            url: "MyController/CreateObject/",
            method: "POST"
        },
        update: {
            url: "MyController/UpdateObject/",
            method: "POST"
        },
        destroy: {
            url: "MyController/DestroyObject/",
            method: "POST"
        },
    },
},

 

 

Our controllers method for CreateObject is:

[HttpPost]
public ActionResult CreateObject(string target)
{
    var result = myService.CreateFolder("NewFolder", target);
    return Json(result, JsonRequestBehavior.AllowGet);
}

 

 

And the json results are:

{
    "SId": "<guid>",
    "ObjectType": "Folder",
    "IsDirectory": true,
    "HasDirectories": false,
    "RootPath": "<some stuff>",
    "NameSpace": "<some stuff>",
    "Path": "myDir\\NewFolder",
    "Name": "NewFolder",
    "Extension": "",
    "Size": 0,
    "PathLocator": "<some stuff>",
    "ParentPathLocator": "<some stuff>",
    "Created": "\/Date(1593736985477)\/",
    "CreatedUtc": "\/Date(-62135571600000)\/",
    "Modified": "\/Date(1593736985477)\/",
    "ModifiedUtc": "\/Date(-62135571600000)\/",
    "Content": null
}

 

 

Thanks for any advice.

 

Doran

Ivan Danchev
Telerik team
 answered on 08 Feb 2021
1 answer
448 views

Hello,

Does the Scheduler support this functionality?:

If the user has made some changes to the event and is closing the window without saving. Is i possible to make a warning saying something like "You have made changes to the event. Do you want to save the changes or close the window?"

//Allan

 

Martin
Telerik team
 answered on 08 Feb 2021
10 answers
1.1K+ views

Hello;

I want to load data using Kendo MVC Grid based on a requirement.

At first I want to load empty grid, then,

I have an html search textbox where I will provide ID, then

based on the ID provided on the search textbox, I want to load data on the grid.

 

Look at the attached pic for more info.

How can I achieve this, if there is a sample code please give me the link.

 

Looking forward for your help.

Thank you

Georgi Denchev
Telerik team
 answered on 05 Feb 2021
6 answers
1.0K+ views

I have an issue in Telerik grid...can you please help me 

 

Here is my Grid code

        @(Html.Telerik().Grid<ClassName>()
              .DataBinding(dataBinding => dataBinding.Ajax().OperationMode(GridOperationMode.Client).Select("GetSearchResult", "Work"))
              .Name("SearchResult")
              .Columns(columns =>
                  {
                      columns.Bound(o => o.TicketId)
                      columns.Bound(o => o.TicketName)

                      columns.Bound(o => o.TicketDescription)

)}

.Scrollable(c => c.Height(3000))
              .Sortable()
              .ClientEvents(events => events.OnComplete("onComplete").OnDataBinding("DataBinding").OnDataBound("SearchResultDataBound").OnRowDataBound("RowDataBound")
              .NoRecordsTemplate("...")
              .Pageable(pager => pager.PageSize(30)

)

 

Like this i have 15 columns in Grid, but my Stored Procedure retuns 40 Columns data, and 500 rows.

when the search data is less than 400 rows from Procedure data is showing in UI, But when the result is more than 400 (max 500 recods from Stored Procedure) records i am getting Internal server error alert popup from telerik.common.min.js   ....

i don't understand why this is happening.

can you please help me.

 

 

tram
Top achievements
Rank 1
Veteran
 answered on 05 Feb 2021
1 answer
551 views
I'm working with the tab control now and need to have a badge attached to one of the tabs. As the user works in the tab, however, the badge content needs to update. I have found references to the JQuery forum for something like this, but am unable to make it work in MVC. What would be the recommended approach for MVC?
Ivan Danchev
Telerik team
 answered on 04 Feb 2021
4 answers
295 views

Hello,

In my custom editortemplate I am checking which type of task/appoinment is being clicked on, so I am able to change the design of the editortemplate based on which type it is. Eg. I am using the "<div data-bind="visible: IsActivityAppointment">".

But how do I determine if it's a new event being created and set the editortemplate from that?

//Allan

Allan
Top achievements
Rank 1
Veteran
 answered on 04 Feb 2021
3 answers
1.0K+ views
Is it possible to use the new RadioGroup control with a Nullable<bool> model property.  It appears the RadioGroupFor expects a string bound property but not sure if there is way to work around that and have it bindable to a Nullable<bool>.
Martin
Telerik team
 answered on 04 Feb 2021
3 answers
420 views

Hello,

I have a grid which displays fine, but when trying to export to excel it exceeds the maxJson limit.  Why can the grid work, but not the export to excel?  Pageable and PageSize(100) on the grid so I'm guessing that the grid brings back data in chunks, but when it tries to export to excel and AllPages(true) that is where the problem is?

Thanks,

John

Ricardo
Top achievements
Rank 1
 answered on 03 Feb 2021
2 answers
3.9K+ views

Hi all

I saw this demo  :  http://demos.telerik.com/aspnet-mvc/styling/radios

I want to know which radiobutton that user checked in client side.

for this one

@(Html.Kendo().RadioButton().Name("engine1").Checked(true).HtmlAttributes(new{@name = "engine"}).Label("1.4 Petrol, 92kW"));

I'm trying to use this

var rbEngine = $("#engine1").data("kendoRadioButton");

but I can't get any value...even checking status...

Am I using wrong method?  

Thanks

 

 

 

 

 

Veselin Tsvetanov
Telerik team
 answered on 03 Feb 2021
Narrow your results
Selected tags
Tags
Grid
General Discussions
Scheduler
DropDownList
Chart
Editor
TreeView
DatePicker
Upload
ComboBox
MultiSelect
ListView
Window
TabStrip
Menu
Installer and VS Extensions
Spreadsheet
AutoComplete
TreeList
Gantt
PanelBar
NumericTextBox
Filter
ToolTip
Map
Diagram
Button
PivotGrid
Form
ListBox
Splitter
Application
FileManager
Sortable
Calendar
View
MaskedTextBox
PDFViewer
TextBox
Toolbar
MultiColumnComboBox
Dialog
DropDownTree
Checkbox
Slider
Switch
Notification
ListView (Mobile)
Pager
Accessibility
ColorPicker
DateRangePicker
Wizard
Security
Styling
Chat
MediaPlayer
TileLayout
DateInput
Drawer
SplitView
Barcode
ButtonGroup (Mobile)
Drawer (Mobile)
ImageEditor
RadioGroup
Sparkline
Stepper
TabStrip (Mobile)
GridLayout
Template
Badge
LinearGauge
ModalView
ResponsivePanel
TextArea
Breadcrumb
ExpansionPanel
Rating
ScrollView
ButtonGroup
CheckBoxGroup
Licensing
NavBar
ProgressBar
QRCode
RadioButton
Scroller
Timeline
TreeMap
TaskBoard
OrgChart
Captcha
ActionSheet
Signature
DateTimePicker
AppBar
BottomNavigation
Card
FloatingActionButton
Localization
MultiViewCalendar
PopOver (Mobile)
Ripple
ScrollView (Mobile)
Switch (Mobile)
PivotGridV2
FlatColorPicker
ColorPalette
DropDownButton
AIPrompt
PropertyGrid
ActionSheet (Mobile)
BulletGraph
Button (Mobile)
Collapsible
Loader
CircularGauge
SkeletonContainer
Popover
HeatMap
Avatar
ColorGradient
CircularProgressBar
SplitButton
StackLayout
TimeDurationPicker
Chip
ChipList
DockManager
ToggleButton
Sankey
OTPInput
ChartWizard
SpeechToTextButton
InlineAIPrompt
TimePicker
StockChart
RadialGauge
ContextMenu
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?