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 7859329
In Process

The Archive Base Latest Questions

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

I am expanding the dropdown on focus which is same as clicking on the

  • 0

I am expanding the dropdown on focus which is same as clicking on the dropdown and selecting an option.

 <script type="text/javascript">
        $(document).ready(function () {
            $('#<%= ddlNature.ClientID %>').focus(function () {
                $('#<%= ddlNature.ClientID %>').attr('size', 6);
            });
            $('#<%= ddlNature.ClientID %>').focusout(function () {
            $('#<%= ddlNature.ClientID %>').attr('size', 1);
        });


          });
</script>


<asp:DropDownList ID="ddlNature" runat="server" class="text" TabIndex="5">

The dropdown expands on focus but the option selected from the dropdown does not get selected ie. the expanded dropdown does not function as dropdown. I am not getting the value selected when i inspect in the firebug.

When I set AutoPostBack to true of the dropdownlist, I get the dropdown value but I don’t want to refresh the page.

Thanks,

  • 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-02T21:52:41+00:00Added an answer on June 2, 2026 at 9:52 pm

    The code is just fine..

    Firebug does not display the select changes..

    If you attach a change handler you will see that it does change it indeed..

    See demo http://jsfiddle.net/gaby/vxDrE/

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

Sidebar

Related Questions

Firefox wraps text inside spans and divs neatly without expanding them. I'm having trouble
I'm expanding on what used to be a pretty simple jQuery accordion script, and
Using .text object property in JavaScript can produce unexpected results in IE8 (blank string
I am creating an expanding search box, when it is on focus it gets
I'm expanding a VB6 application which communicates with small embedded systems to use the
I am expanding the doSvUnit.R script so that it will include the examples in
I have a page in which expanding content flows out of the holding div,
Expanding on recent_posts_on_self below, I want to add an all_recent_posts_on_self method but I'm not
Expanding on Jon Skeet's answer to This Previous Question . Skeet doesn't address the
I am expanding/converting a legacy Web Forms application into a totally new MVC application.

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.