Telerik Forums
Kendo UI for jQuery Forum
1 answer
219 views
Hi,

I'd like to provide data icon attribute to items inside a listview bound to a data source and that uses a template. As 'li' element is added internally when data source is provided to the listview, I can't find any way to show the icon on item's left side.

Thanks
Petyo
Telerik team
 answered on 26 Oct 2012
1 answer
732 views
I am using kendoui widgets with knockoutjs for datasource. I have a checkbox that is data bound to `StartClientFromWebEnabled` observable variable. An input text box is visible only when the checkbox ic checked (`StartClientFromWebEnabled` is true). The input has a required attribute. I want the required validation to be triggered only when the checkbox is checked.


Here is my html: 
 
    <table>
        <tr>
            <td><label for="startClientFromWebEnabled">Client Launch From Web:</label></td>
            <td><input type="checkbox" id="startClientFromWebEnabled" name="startClientFromWebEnabled" data-bind="checked: StartClientFromWebEnabled, enable: IsEditable" onchange="startClientFromWebToggleRequiredAttribute()" /></td>
        </tr>
        <tr data-bind="visible: StartClientFromWebEnabled">
            <td><label for="mimeType">Protocol:</label></td>
            <td>
                <input  id="mimeType" name="mimeType" data-bind= "value: MimeType, enable: IsEditable" />
                <span class="k-invalid-msg" data-for="mimeType"></span>
            </td>
        </tr>
    </table>


I tried some scenarios including setting `onChange event` on the checkbox with the following javascript function adding and removing the required attribute:


    startClientFromWebToggleRequiredAttribute = function () {
        var checkbox = document.getElementById("startClientFromWebEnabled");
        var mimeType = document.getElementById("mimeType");
        if (checkbox.checked) {
            mimeType.setAttribute("required", "required");
        }
        else {
            mimeType.removeAttribute("required");
        }
    }


The problem is I will need this functionality for many dependent properties in my application and my option is to make this function generic with some parameters and call it from the html with the corresponding paramater values like this:


    toggleRequiredAttribute = function (checkboxElement, inputElement1, inputElement2 ... ) {
        var checkbox = document.getElementById(checkboxElement);
        var inputElement1 = document.getElementById(inputElement1);
        if (checkbox.checked) {
            inputElement1.setAttribute("required", "required");
        }
        else {
            inputElement1.removeAttribute("required");
        }
    }


    <input type="checkbox" id="startClientFromWebEnabled" name="startClientFromWebEnabled" data-bind="checked: StartClientFromWebEnabled, enable: IsEditable" onchange="toggleRequiredAttribute('startClientFromWebEnable', 'mimeType')" />


I really do not like this scenario. I wonder is there something like a conditional validation in kendoui that trigger only when some condition is satisfied. Any other suggestions are also welcome. 
Jayesh Goyani
Top achievements
Rank 2
 answered on 26 Oct 2012
6 answers
174 views
Does somebody know the release date for Kendo UI Q3 2012 Beta?
Dustin
Top achievements
Rank 1
 answered on 26 Oct 2012
24 answers
1.5K+ views
Hi,

I am aware that I can pass additional data to the tree view nodes when constructing the HTML list:

<li data-id="id_1234">Item 1</li>


However, I construct my tree view in JS, from a JSON object and have (AFAIK) no way to pass additional data to the nodes. I am thinking of something like:

{
    text: "Item 1",
    data-id: "id_1234"
}


How should I solve this? (Background: I need this "id" to save it into local storage, and later use it when user reloads page so that tree view "remembers" which node should be selected.)

Thanks!
Jacob
Catalin
Top achievements
Rank 1
 answered on 26 Oct 2012
2 answers
249 views
I'm trying to intercept the adding/updating of records to a Grid.

It seems the saveChanges event is triggered at the appropriate time -- just before sending the data to the server, but how can I extract the data that's being saved/updated and how can I prevent the action if necessary?

Thanks
M
Top achievements
Rank 1
 answered on 26 Oct 2012
0 answers
180 views
How to synchronize a node (with its children eventually changed), when the datasource changes externally of treeview.
For instance the changes can be done in the same HTML page in an other control as a grid or a form.
We need to resyncf all thre tree rebinding to datasource or we can reload only a single node?
Sergio
Top achievements
Rank 1
 asked on 26 Oct 2012
0 answers
134 views
how to put validation on multiple checkbox with popup editor.?
Jaymin
Top achievements
Rank 1
 asked on 26 Oct 2012
0 answers
109 views
how to put validation on multiple checkbox with popup editor..?
Jaymin
Top achievements
Rank 1
 asked on 26 Oct 2012
6 answers
1.1K+ views
I have a numeric textbox that looks like this:
@(Html.Kendo().NumericTextBoxFor(m => m.Location.Latitude).Decimals(8).Min(-90).Max(90).Step(.01).Format("{0:0.########}").Events(events => events.Change("placeMarker")))
Every time someone hits the up/down arrow in the numerictextbox, i want the change event (placeMarker) to run.  But it only runs after the person has clicked outside of the numerictextbox, i.e. it loses focus.  Is there a way around this?
Marjan
Top achievements
Rank 1
 answered on 26 Oct 2012
0 answers
70 views
Hi,

Initially i will have the add button and when i click the add button the list view edit mode will appear and then i will add
the data. Then i will add another list and so on and finally i want to save all the listviews at a time.
how can i do that using kendo ui. Hope you will understand my question.

Thanks and Regards,
Srinivas
srinivas
Top achievements
Rank 1
 asked on 26 Oct 2012
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
Drag and Drop
Application
Map
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
DropDownTree
ListBox
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
Licensing
PivotGridV2
ScrollView
Switch
TextArea
BulletChart
QRCode
ResponsivePanel
Wizard
CheckBoxGroup
Localization
Barcode
Breadcrumb
Collapsible
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
TimePicker
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
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
SmartPasteButton
PromptBox
SegmentedControl
LLM Kit
+? more
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Simon
Top achievements
Rank 2
Iron
Iron
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
Marco
Top achievements
Rank 4
Iron
Iron
Iron
Grant
Top achievements
Rank 3
Iron
Iron
Iron
Kao Hung
Top achievements
Rank 1
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?