Skip to main content

All Questions

0 votes
1 answer
25 views

Knockout.js - view model is defined and the template has access to it, but the value of the view model properties cannot be used

Alrighty - I have been stuck fixing some legacy bugs in a project, and it's using Knockout.js. I am very unfamiliar with this library, so please excuse my ignorance. So I have a dialog template that ...
maison.m's user avatar
  • 863
-1 votes
1 answer
998 views

howto retrieve asp.net appSettings key from front-end .js file using knockout.js

I have an asp.net backend application and i am using web.config and other files to store configuration keys. I have a front-end built with javascript files using knockout.js. We would like to know how ...
Luis Soto's user avatar
0 votes
1 answer
16 views

KnockoutJs call function in other viewmodel of applyBindings

On a page I'm calling ko.applyBindings twice to iniate 2 view models. When viewModelOne saves successfully, I want to reload the other view model as some data is added in the backend as they are ...
Rick's user avatar
  • 129
1 vote
1 answer
150 views

Remove duplicates or distinction from array of objects by knockout.js

How to remove duplicates objects from an array by using Knockout.js var ticketgroups = [ {TicketGroup: TicketGroup1, SortOrder: 1}, {TicketGroup: TicketGroup1, SortOrder: 1}, {...
user3774591's user avatar
0 votes
1 answer
35 views

How to update object attributes values in knockout.js at once

How to update object attributes values in knockout.js at once the way i do is one by one like the example here self.person = { id: ko.observable(), name: ko.observable() }; self.person.id("1&...
MOz's user avatar
  • 39
0 votes
1 answer
33 views

knockout foreach is not working for objects in Array

I have an array that has a list of objects and I am trying to loop through it but it seems to not working. <!-- ko foreach: applicationsAndProducts --> <p>Apps and ...
Rnue's user avatar
  • 105
0 votes
1 answer
305 views

Knockout JS How to Data-Bind to Static Form Element

I am trying to data bind a form element in knockout.js. However I don't want the element to be editable in the form, or even display the element to the user. I'm able to correctly data-bind the value ...
recneps's user avatar
  • 1,285
0 votes
1 answer
73 views

Capturing manually entered date before jquery datapicker resets to current date while restricting with Maxdate

I have a datapicker class (datepicker_nfd) that is attached to an input field that uses maxdate to limit the date widget to only current dates. I have a custom knockoutjs binding to display a custom ...
TAD II's user avatar
  • 23
-1 votes
2 answers
124 views

Onclick bind image using knockout js

I want to show image from allDoorColorStandard. HTML: Onclick "color-data" div , i want to update image. In alert i'm getting image URL, now need to bind in image tag. <div data-bind=&...
Jimit Bhavsar's user avatar
0 votes
1 answer
41 views

knockout js , for each loop issue with custom array

I'm trying to get color_name from colors.standard. I have try as given below html but both are showing same array. HTML - not working <div data-bind="foreach: { data: doorColorList, as: '...
Jimit Bhavsar's user avatar
0 votes
1 answer
178 views

How to set value in select options from complex objects using knockout?

How to create two select box from the given object? I need to create two select option box with Country dropdown and State dropdown Selection. const optionsList = ko.observableArray ([ { '...
Rakesh Jesadiya's user avatar
0 votes
1 answer
216 views

knockoutjs data-bind not working in inner loop

Case 1: -- Working HTML Test::<span data-bind="text: $parent.testText"></span> <button data-bind="click: $parent.testbtn"></button> JS numberOfClicks : ko....
Jimit Bhavsar's user avatar
0 votes
0 answers
55 views

Why my function is being called on by itself

Im using knockout.js and MVC .NET I was hoping to create a button foreach service that I have. That button should just populate some values in textboxes. But, however, that function click: $parent....
lonelydev101's user avatar
  • 1,731
0 votes
0 answers
33 views

knockout losing model when pressing button for the second time

Got an old project in .net that needs few new features. We have a major problem with knockout somehow when pressing button for the first time everything works as it should, but when it is pressed for ...
Jānis Bērziņš's user avatar
0 votes
2 answers
67 views

knockout.js in MVC - not working binding in html table

why I cant do click binding for button in tags of some table? if I move button outside the table it works? <td> <div> You've clicked <span data-bind="text: ...
lonelydev101's user avatar
  • 1,731

15 30 50 per page
1
2 3 4 5
16