Questions tagged [angularjs-ng-change]

The ngChange allows to evaluate given expression when user changes the input.

Evaluate given expression when user changes the input. The expression is not evaluated when the value change is coming from the model.

Note, this directive requires ngModel to be present.

Usage

as attribute

<input
  ng-change="expression">
...
</input>

Parameters

ngChange – {expression} – Expression to evaluate upon change in input value.

References:

http://docs.angularjs.org/api/ng.directive:ngChange

265 questions
0
votes
2 answers

Angular js apply color picker value

I want to apply the color picker runtime value as a background color of span text. How can I use model as a color value? HTML:
Ashwin
  • 12,081
  • 22
  • 83
  • 117
0
votes
2 answers

ng-change not firing but ng-click does in ng-repeat

I have a couple of arrays and am looping through them to build a table. The first header row is an array of column names and the second a row of select boxes that the user will use to select to map to the above column names

CSV…

0
votes
1 answer

ANgularJS binding element to function output with ng-change

AngularJS beginner here. Writiung a simple page to learn. All it does is take a user input and then apply an operation to it (*10) and display that in the page. I have no idea why this is not working, no value for {{funding.needed}} is ever…
Mlalahoi
  • 1,660
  • 2
  • 13
  • 11
0
votes
2 answers

Updating value in ng-repeat based on dropdown

I'm building a table using ng-repeat to display some information. One of the columns displayed is a 'Weight' column. We store all the weight in kilograms in the database, but need to give the user an option to display the weight in pounds. I have a…
0
votes
1 answer

AngularJS - Data binding not working

Sorry, english is my second language. Here is my problem. I had bound two textboxes to the scope. Each textbox needs to affect the other on changes. You'll understand that it cause conflict. From now, I've got that :
0
votes
1 answer

How do you get an array of selects values from multiple select boxes?

I am trying to get an array of the values of dynamically generated select boxes in a table. How could you get an array or another data type of these values? Here is the table:
Personal Action Field(from…
Amanda Watson
  • 340
  • 2
  • 3
  • 14
0
votes
0 answers

How do I prettify a value after user input with angularjs?

I want to find a consistent way to custom prettify some input values after user input. (The underlying model has to change together with the value.) What is the best practice in Angularjs? $watch, ng-change, doing a prettified="myFormatterFunction"…
Barney Szabolcs
  • 11,846
  • 12
  • 66
  • 91
0
votes
2 answers

Angular.js : checkbox is not checked by the user but I need ng-change

I have a custom jquery-plugin that will hide the real checkbox and show an enhanced component instead of the real one. for this code
0
votes
3 answers

AngularJs Get the value of the selected option

How can i get the value of the selected option on the ng-change "ReadData" Template is an array of Title, Id, and body on the function updateValue(val), i 've written like the following $scope.updateValue=function(val) { …
surendher
  • 1,374
  • 3
  • 26
  • 52
0
votes
1 answer

How to update model value on user input via Angular JS?

I am trying to build an app for calculating tax using angular.js as a tutotrial for me to understand the framework. First thing I noticed is that user input is by default assumed to be string, which obviously makes sum function a string…
irwin
  • 115
  • 1
  • 2
  • 10
0
votes
3 answers

how to identify whether the textbox value is change or not?

I have mentioned my HTML.
in my JS file function myCtrl($scope){ $scope.name=//this field comes from DB say 'ABC' } My question : When my html is get loaded, it will…
0
votes
1 answer

ng-change to only execute after a user has stopped typing

I am developing a search option for my web app written in angularjs. The situation now is the following: a request to the backend server is fired with ng-change every time something is typed into the search field, this can lead to an unneccessary…
user1354603
  • 4,034
  • 4
  • 31
  • 43
0
votes
0 answers

Model reservation with 2 selects

Hi I am developing a car park reservation system, I have an array of objects that look like this $scope.availability = [ { date: "Mon, 20 June 2014", spaces: [ 1, ..., …
DrogoNevets
  • 1,456
  • 3
  • 18
  • 34
0
votes
1 answer

Regular Expression not matching in JavaScript and AngularJS with ng-change

I am trying to get my path variable in this page to change the spaces and punctuation characters, as the user types it in. Here is the corresponding code:
Games Brainiac
  • 80,178
  • 33
  • 141
  • 199
1 2 3
17
18