Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7853983
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T19:52:53+00:00 2026-06-02T19:52:53+00:00

I have an asp.net textbox that is disabled: <asp:TextBox ID=txtEmpName runat=server Enabled=false></asp:TextBox> Using jQuery,

  • 0

I have an asp.net textbox that is disabled:

<asp:TextBox ID="txtEmpName" runat="server" Enabled="false"></asp:TextBox>

Using jQuery, I then enable or disable the textbox depending upon two radio buttons that are clicked.

$(document).on("change", "input[id*='_rbtnIsFullTime_']", function ($e) {
  if ($(this).val() == "1")
    $("input[id$='_txtEmpName']").removeAttr('disabled');
  else
    $("input[id$='_txtEmpName']").attr('disabled', 'disabled');
});

The problem that I am running into is when the textbox is enabled via jQuery, any text that is then entered into it by the user is not submitted with the page because the ViewState still shows the textbox as being disabled when the page was originally rendered.

Any ideas on how to get around this and make the ViewState play nicely with jQuery?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-02T19:52:57+00:00Added an answer on June 2, 2026 at 7:52 pm

    Create a second textbox with the same text and make ti disabled. Then just toggle the visibility of the two boxes accordingly?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have problem while using jquery maskedinput with asp.net textbox. I have a check
i have an asp,net textbox like this <asp:TextBox readonly=true ID=txtLastService runat=server></asp:TextBox> when i tried
I have an ASP.NET MVC Partial View that contains a Html.TextBox that is configured
I have a asp.net web content from that have a asp.net textbox and I
the problem is that I do have an ASP.NET TextBox in a FormView with
I have a ASP.NET web page that contains many textboxes. Each textbox has a
I have a .Net page with some textboxes, which are sometimes disabled. <asp:TextBox ID=TextBox1
Im trying to implement an asp.net textbox using the jQuery UI Autocomplete widget http://jqueryui.com/demos/autocomplete/#remote
I'd like to have an asp.net textbox that people can paste content into and
C sharp newbie question...I have a simple asp.net form that has a textbox that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.