[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

6.8

javascript element.focus does not work with IE6 and dropdown list box

Asked by RosalindP in JavaScript, Hypertext Markup Language (HTML), Internet Explorer Web Browser

Tags: javascript, focus(), IE6, dropdown list box

Hi:
I have a simple data entry form which I have inherited from another programmer and I added several fields to it.  When I set the tabindex, the fields were not tabbed to in the order proscribed.  After some pondering I realized that the problem was nesting tables.
To solve the problem I wrote a little javascript setFocus function which I accessed from the clientside onblur.  This solved the problem until I got to the dropdown list boxes that I added.  The first ddl is selected, but the second one is skipped.  This only happens in IE6.  IE7 is fine.  I do not need to check for other browsers.  Does anyone know what the workaround for IE6 is?  Relevant code is below.  I am using .net framework 3.5 and Visual Studio 2008.

Thank you.
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
javascript function
        function setFocus(field) {
            document.getElementById(field).select; 
            document.getElementById(field).focus();
        }
 
HTML
This is contained within a table.
         <tr>
                                    <td class="ObservationLabelBold" style="text-align: right; white-space: nowrap;">
                                        <asp:Label ID="lblDied" runat="server" Text="Died from Illness:"></asp:Label>
                                    </td>
                                    <td>
                                        <asp:RadioButtonList ID="rbDied" runat="server" RepeatDirection="Horizontal" CssClass="ObsRadioButton"
                                            Height="16px" TabIndex="10" onblur="setFocus('ddlLHJSpecies');">
                                            <asp:ListItem Value="1">Yes</asp:ListItem>
                                            <asp:ListItem Value="2">No</asp:ListItem>
                                            <asp:ListItem Value="9">DK</asp:ListItem>
                                            <asp:ListItem Value="8">NA</asp:ListItem>
                                        </asp:RadioButtonList>
                                    </td>
                                </tr>
                                <tr>
                                    <td style="text-align: right; white-space: nowrap;">
                                        <asp:Label ID="lbLHJSp" CssClass="ObservationLabelBold" runat="server" 
                                            Text="LHJ Species/Organism:" TabIndex="0"></asp:Label>
                                    </td>
                                    <td style="white-space: nowrap;">
                                        <asp:DropDownList ID="ddlLHJSpecies" runat="server" Width="176px" TabIndex="11" CssClass="ObservationText"
                                        onblur="tieTextBox(this,'ddlLHJSpecies','txtSpOther','Other');setFocus('ddlLHJSerogroup');">
                                        </asp:DropDownList>
                                    </td>
                                    <td >
                                    <asp:TextBox id="txtSpOther" runat="server" Width="100%" TextMode="SingleLine"
                                            CssClass="ObsReadOnlyAppSet ObservationText" MaxLength="100" 
                                            Enabled="False" TabIndex="-1"></asp:TextBox>
                                    </td>
                                </tr>
                                <tr>
                                    <td style="text-align:right; white-space: nowrap;">
                                        <asp:Label ID="lbLHJSero" CssClass="ObservationLabelBold" runat="server" 
                                            Text="LHJ Serotype/Serogroup:" TabIndex="-1"></asp:Label>
                                    </td>
                                    <td style="white-space: nowrap;">
                                        <asp:DropDownList ID="ddlLHJSerogroup" runat="server" Width="176px" TabIndex="12"
                                            CssClass="ObservationText"  
                                            onblur="tieTextBox(this,'ddlLHJSerogroup','txtSeroOther','Other');setFocus('txtLHJNotification')">
                                        </asp:DropDownList>
                                    </td>
                                     <td >
                                    <asp:TextBox id="txtSeroOther" runat="server" Width="100%" TextMode="SingleLine"
                                            CssClass="ObsReadOnlyAppSet ObservationText" MaxLength="100" 
                                             Enabled="False" TabIndex="-1"></asp:TextBox>
                                    </td>
</tr>
[+][-]08/04/09 06:50 PM, ID: 25019687Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/04/09 06:53 PM, ID: 25019696Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/04/09 06:57 PM, ID: 25019713Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/05/09 12:36 AM, ID: 25020900Assisted Solution

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 30-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]08/05/09 09:22 AM, ID: 25025167Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/05/09 10:48 AM, ID: 25026091Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zones: JavaScript, Hypertext Markup Language (HTML), Internet Explorer Web Browser
Tags: javascript, focus(), IE6, dropdown list box
Sign Up Now!
Solution Provided By: RosalindP
Participating Experts: 2
Solution Grade: A
 
[+][-]08/05/09 11:37 PM, ID: 25030612Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/06/09 09:35 AM, ID: 25035366Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]08/07/09 12:19 AM, ID: 25040470Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]08/07/09 12:19 AM, ID: 25040474Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-89 - Hierarchy / EE_QW_3_20080625