0

this may sound silly but need to know how i could enable and disable textbox on checkbox click event in mvc. I am populating few items in a list and need to fill quantity in a textbox after corresponding checkbox is checked..

1 Answer 1

1

I would suggest using jQuery to pull this one off.

Your code would look something like this if you use jQuery:

$("#yourCheckBox").click(function () {
    $('#yourTextBox').attr("disabled", $(this).is(':checked'));
});
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.