Telerik Forums
Kendo UI for jQuery Forum
3 answers
91 views
Hi Team,

We are developing an Intuition platform, having Auto complete functionality in the editor. Here we are handling the editor data as expressions,

In the editor there will be any number of variables, operators, text and comments can use by the user. Each line is separated in <p> and inside that all the nodes are formatted.

For Example:
Variables and Operators placed in <a> tags
Comments and default text in <span> tags 

We are having typing and Editing functionality, if the typing text is matching in the variable or operator text then we have to place the string in <a> tag.
When the user can edit the expression anywhere in the editor. If they edit the variable text,
 For example:

Consider "Alpha0" is a variable which is formatted to <a href="#" style="color: #a50;">Alpha0</a>, the user edited the text to "Alha0", after the editing the node formatting to <Span style=" color: black;">Alha0</span> 

The color format change is working when typing and editing in Chrome. In IE 10 is not supporting in all the cases.

If I try to update in the middle of the expression the caret position is jumping to first node. The below code is using for getting the caret position

var selection = editor.getSelection();
var selectedElement = selection.focusNode;
var range;

if (selectedElement.nodeName != 'P'
&& selectedElement.nodeName != 'DIV') {
range = editor.getSelection().getRangeAt(0).endOffset;
} else if ((selectedElement.nodeName == 'P' || selectedElement.nodeName == 'A')) {
var index = editor.getSelection().getRangeAt(0).endOffset;
if (index != 0) {
selectedElement = selectedElement.childNodes[index - 1];
range = selectedElement.textContent.length;
} else if (selectedElement.childNodes.length > 0) {
selectedElement = selectedElement.childNodes[index];
range = index;
}
}

If the text is editing in the middle of <a> tag it should change to <span> tag based on the validation, in that case editor's caret position getting as "0". So it jumping to the first node. Please help us with this issue.

Thanks in Advance.






















Alex Gyoshev
Telerik team
 answered on 11 Mar 2014
5 answers
167 views
ok, using fiddler and chrome tools I don't see a POST go out to my web service for the following when using "people.add"

var people = new kendo.data.DataSource({
      transport: {
        read: {
            type: 'GET', //url being set dynamically and works fine for the read
            dataType: 'json'
        },
        create: {
          url: uri,     //http://wwww.mysite.com/api/people
          type: 'POST',
          dataType: 'json'
        }
      }      
    });
 
//the call:
// data structure on web api POST has same fields as below
//the "add" is working locally but a POST is never made back to the remote web api
// i have tried with and without the JSON.stringify
 people.add(JSON.stringify({FirstName: $("#bfname").val(), LastName: $("#blname").val(), Phone: $("#bphone").val(),
  Email: $("#bemail").val(), ShowId: showID, HostId: 1, DealerId: 1, Note:$("#bemail").val(),  Photo: '', Id: -1}));

i have read posts for hours and hours...tried almost everything i read and can't get the create to POST to my web service.

Thanks for any help.
Richard
Nikolay Rusev
Telerik team
 answered on 10 Mar 2014
2 answers
126 views
Hi guys
I've been using the Fluentenium framework in order to do automation tests under Selenium and i'd like to create some tests that can access the iframe that gets rendered when the Kendo UI Text Editor gets created, or somehow programmatically add content / extract content from it using this type of automation.
Do you guys support Fluentlenium at all? If not, are there other alternatives to interact with the Kendo UI Text Editor programmatically using automation?

Thanks
Roman Jaquez
Roman
Top achievements
Rank 1
 answered on 10 Mar 2014
1 answer
175 views
Kendo.UI 2013.3.1324

I am cutting/pasting sample code from MVC grid control for local data.  My IEnumerable list of data is populated into SearchResults.  When I look at the HTML source, I see all the row and column data in the table, and repeated again in the kendoGrid() method as JSON.  Not sure why it is repeated again here.  What actually renders though, is that I see all the data in the grid flash for a millisecond on page load, but then it shows "No items to display" with empty grid.  Obviously when it hits the kendoGrid() method, something goes wrong.  If I add Deferred(true), then the grid is populated, but paging does an undesirable postback.  So, why is the code populate both the HTML table, and the JSON passed to kendoGrid() method?

​ @(Html.Kendo().Grid(Model.SearchResults)
.Name("GridResults")
.Columns(columns =>
{
columns.Template(p => @Html.ActionLink("Edit", "Edit", new { Id = p.RecipeId }));
columns.Bound(p => p.ProductType).Title("Type");
columns.Bound(p => p.DisplayRecipeId).Title("Recipe ID").Width(130);
columns.Bound(p => p.RecipeName).Title("Recipe Name").Width(130);
columns.Bound(p => p.Status).Width(130);
columns.Bound(p => p.CreateDate).Title("Create Date");
columns.Bound(p => p.RevisedDate).Title("Revised Date");
})
.Pageable()
.Sortable()
.Scrollable(scr => scr.Height(350))
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(15)
.ServerOperation(false)
)
)
Daniel
Telerik team
 answered on 10 Mar 2014
6 answers
130 views
I've got an issue with an area chart where by its not filling 100%, when it should.

See the chart below… 
I've blocked out the legend for client reasons.
The obvious one is to the right, but there are smaller areas that don’t fill 100%.




Along each point of the categoryAxis, the value in the series sum to 100% (I have checked in the data, I am totally sure of this).

I think what might be the problem is that along each point, there is not always the same number of items in the series (items in the legend - not sure of the terminology!).
Jul-08 may have 10 values.
Sep-12 may have 8 values.
Although they all sum to 100%.

I'm wondering if kendo is taking the number of data fields in the first category point and using that to calculate the rendering.

I have tried to use the same data with highchart, the result is really what I would expect to see.  Some white gaps for missing data, but all going to 100%.





Is there a setting or something that I am missing in kendo to achieve this?










T. Tsonev
Telerik team
 answered on 10 Mar 2014
1 answer
121 views
Although I am using AngularJS with the kendo-angular - I am trying to use the Grid, I want to bind the grid to an array, I read that if I am providing array as dataSource it will automatically convert it to dataSource, am I am loosing the direct binding? cause I want to change the array content and automatically the grid will be updated.

When I am trying to use array and not kendo-datasource i am getting exception

TypeError: Unable to get property 'create' of undefined or null reference
   at toDataSource (http://localhost:64968/Client/lib/angular/angular-kendo.js:16:9)
   at Anonymous function (http://localhost:64968/Client/lib/angular/angular-kendo.js:32:13)
   at $digest (http://localhost:64968/Client/lib/angular/angular.js:11501:21)
   at $apply (http://localhost:64968/Client/lib/angular/angular.js:11740:13)
   at Anonymous function (http://localhost:64968/Client/lib/angular/angular.js:13265:25)
   at completeOutstandingRequest (http://localhost:64968/Client/lib/angular/angular.js:4021:7)
   at Anonymous function (http://localhost:64968/Client/lib/angular/angular.js:4327:7) 
Petur Subev
Telerik team
 answered on 10 Mar 2014
1 answer
240 views
For some reason my kendoComboBox, with server side filtering, is hitting my MVC controller twice, the first time with no data. Any idea why this is happening? 

Also another note, I do not need all the fancy filter criteria that is sent by kendo, I send a term, and perform an OR search across address fields. 


$('#ELEMENT').width(700).kendoComboBox({
dataSource: addressDS,
dataTextField: "NAME",
dataValueField: "ID"
});


var addressDS = new kendo.data.DataSource({
        schema: {
            model: {
                id: "ID",
                fields: {
                    ID: {type: "number"},
                    NAME: {type: "string"},
                    ADDRESS1: {type: "string"},
                    CITY: {type: "string"},
                    STATE: {type: "string"},
                    ZIP: {type: "string"},
                    COUNTRY: {type: "string"},
                    
                }
            },
            data: function(data) {
                return data.Results;
            },
            total: function(data) {
                return data.ResultCount;
            }
            
        },
        transport: {
            read: {
                type: 'json',
                url: '/Address/Autocomplete'
            },
            parameterMap: function(data, type) {
                return {
                    term: $('#ELEMENT').val()
                };
            }
        },
        serverFiltering: true
    });
Georgi Krustev
Telerik team
 answered on 10 Mar 2014
4 answers
184 views
Hi,

Since the latest version the app.pane.history became obsolete? (Only contains one item).
Is there any way to know the amount of items in the history now?



Dorian
Top achievements
Rank 2
 answered on 10 Mar 2014
1 answer
66 views
See this page:

http://162.243.119.49/FAQ/test1.php

Notice how the pagination section at the bottom the layout is all over the place. Im not using any other css files and it seems to be finding the css files fine. Is there something small im missing that would explain the messed up layout. Also if you compare it to the examples on the demo my rows also seem to be much bigger too.

Any help appreciated
Dimo
Telerik team
 answered on 10 Mar 2014
3 answers
137 views
Hello,

I would like to create a line chart with a visible crosshair and an event handler for plotAreaClick. The event handler is needed to process the data point category (event data: e.category). The event is not fired if the mouse pointer touches the crosshair.

Is there a similar event for clicking the crosshair which provides the category – or any other solution for this problem?
Hristo Germanov
Telerik team
 answered on 10 Mar 2014
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
AICodingAssistant
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
+? 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?