I have three text boxes having id text1, text2, text3 and one checkbox having id check. I am displaying something in first textbox let\'s say 10. Now if i will check checkbo
$('#check').change(function(){if($(this).is(':checked'))$('#text2').val(20);});
If you want to clear the value when it is unchecked use:
$('#check').change(function(){if($(this).is(':checked'))$('#text2').val(20);else $('#text2').val(''); });