Questions tagged [bindinghandlers]

26 questions
1
vote
1 answer

Knockout.js Bindinghandlers Bootstrap.DatePicker

I'm using Twitter Bootstrap.DatePicker with knockout. The problem that I'm having is that I can't get it to work properly. It's working fine when there is an initial date, but when there is no initial date I am getting the following error: Uncaught…
1
vote
1 answer

Format Currency Knockout Binding

Can't get my custom bindingHandlers to work. The currency doesn't get formatted on load, but does when you enter a value in the textbox. I need it to format on load. I am using this tool: Format Currency ko.bindingHandlers.currency = { init:…
jmogera
  • 1,689
  • 3
  • 30
  • 65
0
votes
1 answer

How to use a bindingHandler twice

I have a binding handler for the JSONEditor npm package. My program will enable the user to compare two different JSON files inside those panels. My bindingHandler looks like this: var editor = undefined; ko.bindingHandlers.jsoneditor = { init:…
TheRev
  • 124
  • 13
0
votes
2 answers

Binding handler 'value is not a function' knockoutJS

I am stumped as to what is causing the problem here as this binding handler normally works fine (below) ko.bindingHandlers.buttonGroupChecked = { init: function(element, valueAccessor, allBindingsAccessor, viewModel, bindingContext) { var value…
GrahamTheDev
  • 22,724
  • 2
  • 32
  • 64
0
votes
1 answer

Knockout custom binding not updating

Please check what I am doing wrong. The update part of my custom bindinghandler does not executes when I create a control in javascript. I have an Add function that create a row in a table. Controls that are bound to the custom binding does executes…
Righardt
  • 31
  • 7
0
votes
1 answer

knockout binding using a dropdown to prepopulate a textbox

I have a select element and a text input element on a modal dialog box. I want to select an option from the select input and use the value to prepopulate the text input element (this just helps the user with a prefilled name and then allows the user…
Alan Alcock
  • 787
  • 1
  • 11
  • 26
0
votes
2 answers

.scroll() jquery is not working within knockout custom binding handler?

I use Durandal (requireJS + knockoutJS) with jQuery jquery 1.10.2 + knockoutjs 2.3.0 + requirejs even a simple code won't work $('#table1').scroll(function(){ alert(''); }); even fadeOut(); fadeIn() are not working but EACH function is…
VJPPaz
  • 917
  • 7
  • 21
0
votes
1 answer

Knockout custom binding handler for Polymer core-selector - setting 'selected' attribute is not updating the element

The binding handler and the HMTL. ko.bindingHandlers.radioGroupChanged = { init: function (element, valueAccessor, allBindingAccessor, viewModel, bindingContext) { var value = valueAccessor(); var newValueAccessor = function…
Bserk
  • 91
  • 4
  • 12
0
votes
1 answer

Knockout binding works when typed, but not when bar-coded

I have a custom Binding that works on Keyup and when users manually type in data the valueAccessor().call works just fine and enters the desired next function. However, when we barcode the same data, and send the same return key, (i have checked…
andy
  • 485
  • 1
  • 7
  • 16
0
votes
2 answers

Custom knockout binding fires twice, unexpectedly

I have written a custom binding handler to bind my viewmodel data to a highcharts chart. This really has 2 parts, one binds the initial config required for highcharts, the second binds the series to the chart. here is the bindingHandler…
Jamiec
  • 133,658
  • 13
  • 134
  • 193
0
votes
1 answer

Knockout Binding with Virtual Elements Not Working

I'm working on some custom bindings, and in one I'd like to be able to show a table from some arrays of strings. fiddle I simplified it down to this custom binding: ko.bindingHandlers.table = { init: function tableBinding(element, valueAccessor,…
Brigand
  • 84,529
  • 20
  • 165
  • 173
1
2