I have a change functions as below: All i want is whan a user clicks the button and the value is less than zero change the backgoundcolor of the textbox and viceversa if its greater that. But it doesn't seem to work any ideas?
$("input[name$=Text1]").change(function () {
var value = $(this).val();
$("p#pcms").text(value);
var PerMonth = value-Pmmc;
$("input[name$='spmtext']").val(PerMonth);
if (PerMonth <0){
$("input[name$='spmtext']").css("background-color","#FFFF00");
}
if (PerMonth >0){
$("input[name$='spmtext']").css("background-color","#004080");
}
}).change();