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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T04:54:18+00:00 2026-05-31T04:54:18+00:00

I have the following HTML: <select id=testMe name=test multiple=multiple size=5 style=width:270px> <option value=test1>test1</option> <option

  • 0

I have the following HTML:

<select id="testMe" name="test" multiple="multiple" size="5" style="width:270px">
    <option value="test1">test1</option>
    <option value="test2">test2</option>
    <option value="test3">test3</option>
    <option value="test4">test4</option>
    <option value="test5">test5</option>
    <option value="test6">test6</option>
    <option value="test7" selected="selected">test7</option>
    <option value="test8">test8</option>
</select>

And the following jQuery code:

MySite.Common.moveScrollBar = function(selectID) {

    var testSel = jQuery('#'+selectID + ' :selected').val();

    jQuery('#'+selectID + ' option[value=' + testSel +']').attr('selected', true);  
};

The reason for the jQuery code is to show the selected option in a select box when a page is initially loaded (fixed size select with dynamic number of values).

I have had to do this as IE does not seem to move the scrollbar to the selected item in the list when the HTML is initially rendered on page load.

Any ideas?

  • 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-05-31T04:54:20+00:00Added an answer on May 31, 2026 at 4:54 am

    Auto scrolling does not work in IE if multiple="multiple" is set.
    See similar question:
    How to get first selected item in an asp:ListBox with SelectionMode="Multiple" to appear at top?

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

Sidebar

Related Questions

I have the following HTML: <div style=30px;> <table width=100%;> <tr> <td> <SELECT name=guidelinks> <OPTION
I have the following html element <select id=selectStates size=5 multiple=multiple class=box> <option value=tx>Texas</option> <option
I have the following HTML which defines my selector: <select name=zoom_cat[] style=margin-left:15px;> <option value=-1
I have the following HTML: <div data-name=countrySelectorRoot> <select> <option value=C1>Country 1</option> <option value=C2>Country 2</option>
if i have a dropdown with the following html: <select id=myDropdown name=myDropdown> <option value=6>Six</option>
i have the following html code <select id=c0 name=countries onchange=show_other()> <option value=1>something</option> <div id=c1>
I have the following HTML select element: <select id=publisher name=publisher> <option value=10>Google</option> <option value=11>Yahoo</option>
I have the following HTML code: <select name=forma> <option value=Home>Home</option> <option value=Contact>Contact</option> <option value=Sitemap>Sitemap</option>
I have the following HTML <select onchange=this.form.submit() name=name> <option value=9995101E01#17201044055PM>9995101E01#17201044055PM</option> <option value=GRR-Example>GRR-Example</option> <option value=admin>admin</option>
I have the following html: <select type=text name=City value=> <option>city1</option> <option>city2</option> <option>city3</option> i am

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.