I have a problem when angular\'s ng-change is called when model is changed programmatically.
$scope.sendMessage = function() {
$scope.message = \"Message sen
The ng-change callback is changed on each model change, and it treats the initial setup as such change. What you might want to do is to run desired code only after user interacts with it. You can check the $touched property of the field:
$scope.sendMessage = function() {
if ($scope.exampleForm.mySelectBox.$touched) {
$scope.message = "Message sent";
}
}