Click to See Complete Forum and Search --> : Adding Numbers
Cobra-tat
09-04-2007, 06:28 PM
I have a problem, i have made a webform that uses numerous drop down list. when i select a number from a list the web site loads the number but when i chose another number from a different list the webpage only remembers the last number list that chose. how can i get the different lists to remember to add all the numbers that i have chosen when the page gets reloaded?
Phil Weber
09-05-2007, 02:17 AM
I don't understand. I created an ASP.NET Web project with a single Web form. On that form I placed five dropdownlists, each containing the values 1 through 10, and a Submit button. When I run the project, I am able to select values from the dropdownlists and submit the form; when the page reloads, the values I selected are still visible in the dropdownlists.
What are you doing differently?
Cobra-tat
09-05-2007, 08:51 AM
what i'm doing with numerous list is
Protected Sub ddlRLIIChallengeQty_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ddlRLIIQty.SelectedIndexChanged
RLIIPrice = Val(txtRLIIChallengePrice.Text)
RLIIQty = ddlRLIIQty.SelectedIndex
RLIISub = RLIIPrice * RLIIQty
txtRLIISub.Text = FormatCurrency(RLIISub, 2)
ExamTotal = WorkZoneSub + SMISub + SMIISub + TSInpSub _
+ TSISub + TSIISub + RLISub + RLIISub
txtExamTotal.Text = FormatCurrency(ExamTotal, 2)
If (ddlRLIIQty.SelectedIndex >= -1 And ddlRLIIQty.SelectedIndex <= 0) Then
txtRLIISub.Text = String.Empty
End If
End Sub
So when i click on a list the price adds and totals but when i click on a different list the price loads the new price but does not add the previous list and the new list.
That is about the best i can describe it.
devx.com
Copyright Internet.com Inc. All Rights Reserved