Advertisement

04.17.2008 at 06:38AM PDT, ID: 23330768
[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!

9.0

Problem with PostBack

Asked by smdevivo in .NET Framework 2.x, .Net Editors & IDEs

Tags:

I have a page/form (Page1) with a number of fields (text boxes, drop downs, etc.).  Currently all items Insert a record when Continue is selected and the "Success" of that action then redirects to Page2.  That's all been working fine.

I now want to add a drop down which, when an item is selected from the list, populates another drop down menu (on the same page) based on that selection.  I have this working fine on a stand-alone test page that does not insert a record.  But when I place these items into the page with the "Insert Record" action, it immediately performs the insert and moves to Page2.  I realize this is probably normal.

What I'm looking for is: How do I have a "PostBack to the same page" for the two drop downs to interact and do their things and then, when the Continue button is selected, do the "Insert record action and the associated Success URL"?

I have attached my code for review - it is the bottom two drop down menus in question.
ThanksStart Free Trial
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:
<form id="frmRoofSys01" name='frmRoofSys01' method='POST' action="" runat='server'>
 
<asp:DropDownList ID="RoofAccess" runat="server">
      <asp:ListItem value="No Selection Made">Select Roof Access</asp:ListItem>
      <asp:ListItem value="Ladder-On Site">Ladder-On Site</asp:ListItem>
      <asp:ListItem value="Ladder Required">Ladder Required</asp:ListItem>
      <asp:ListItem value="Roof Hatch">Roof Hatch</asp:ListItem>
      <asp:ListItem value="Other">Other</asp:ListItem>
</asp:DropDownList>
 
<asp:DropDownList ID="RoofSlope" runat="server">
      <asp:ListItem value="No Selection Made">Select Roof Slope</asp:ListItem>
      <asp:ListItem value="0">0"</asp:ListItem>
      <asp:ListItem value="1/8">1/8"</asp:ListItem>
      <asp:ListItem value="1/4">1/4"</asp:ListItem>
      <asp:ListItem value="1/2">1/2"</asp:ListItem>
      <asp:ListItem value="3/4">3/4"</asp:ListItem>
      <asp:ListItem value="1">1"</asp:ListItem>
      <asp:ListItem value="1-1/4">1-1/4"</asp:ListItem>
      <asp:ListItem value="1-1/2">1-1/2"</asp:ListItem>
      <asp:ListItem value="1-3/4">1-3/4"</asp:ListItem>
      <asp:ListItem value="2">2"</asp:ListItem>
      <asp:ListItem value=">2">>2"</asp:ListItem>
      </asp:DropDownList>
 
<asp:DropDownList ID="RoofDeckType" runat="server" AutoPostBack="true" >
        <asp:ListItem Value="No Selection Made" Selected="selected">Select Roof Deck Type </asp:ListItem>
        <asp:ListItem Value="Metal">Metal </asp:ListItem>
        <asp:ListItem Value="Wood Plank">Wood Plank </asp:ListItem>
        <asp:ListItem Value="Structural Concrete">Structural Concrete </asp:ListItem>
        <asp:ListItem Value="Plywood">Plywood </asp:ListItem>
        <asp:ListItem Value="Oriented Strand Board">Oriented Strand Board </asp:ListItem>
        <asp:ListItem Value="Gypsum">Gypsum </asp:ListItem>
        <asp:ListItem Value="Tectum">Tectum </asp:ListItem>
        <asp:ListItem Value="Light-Weight Insulating Concrete over Steel Deck">Light-Weight Insulating Concrete over Steel Deck</asp:ListItem>
        <asp:ListItem Value="Light-Weight Insulating Concrete over Concrete Deck">Light-Weight Insulating Concrete over Concrete Deck</asp:ListItem>
        <asp:ListItem Value="Other">Other </asp:ListItem>
        <asp:ListItem Value="N/A">N/A </asp:ListItem>
      </asp:DropDownList></td>
 
<asp:DropDownList ID="RoofDeckThickness" DataSource="<%# dsRoofDeckThickness.DefaultView %>" DataTextField="RoofDeckThickness" DataValueField="RoofDeckThickness" runat="server"></asp:DropDownList>
 
      <asp:Button ID="Continue" Text="Continue" runat="server" />
            
  <input type="hidden" name="MM_update" value="frmRoofSys01" />
</form>
[+][-]04.17.2008 at 06:42AM PDT, ID: 21376909

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

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

 
[+][-]04.17.2008 at 07:41AM PDT, ID: 21377590

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 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.18.2008 at 08:03PM PDT, ID: 21390980

View this solution now by starting your 7-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: .NET Framework 2.x, .Net Editors & IDEs
Tags: ASP.NET VB
Sign Up Now!
Solution Provided By: sunilj20
Participating Experts: 3
Solution Grade: A
 
 
[+][-]05.12.2008 at 07:32PM PDT, ID: 21551882

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

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

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628