How can I make a text field = a field on a previous part of a multi part form

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • gmiotke
    New Member
    • Mar 2010
    • 4

    How can I make a text field = a field on a previous part of a multi part form

    I know that this is easy for those that know but alas this is not me ;)

    I have a multi part form that is going to write to a dB.

    As a point of reference I can offer geico.com (i.e., the quote process) as a model for my project.

    I need to write a record on the first page and then use the auto number generated from this to populate the child records with the parent's key field.

    What I was hoping to do is write the record and then send the data from the dB to the second form. Iwill then need to repeat this process for the children of the child

    Please advise...and take it easy on me. I am only moderately familiar with ASP.net

    one thing to add is that i am not forcing the user to create an account in order to maje the initial inquiry, only if they wish to reaccess theinformation at a later date (again very similar to Geico.com
    Last edited by gmiotke; Mar 1 '10, 08:17 PM. Reason: ADDENDUM:
  • semomaniz
    Recognized Expert New Member
    • Oct 2007
    • 210

    #2
    Why don't you used Wizard tool and do every thing at once.

    Comment

    • gmiotke
      New Member
      • Mar 2010
      • 4

      #3
      Thanks for the suggestion. I will investigate it further. Could you explain a littel more as to how this will solve my need to put the parent ID field into the child table?

      Thank you in advance

      Comment

      • semomaniz
        Recognized Expert New Member
        • Oct 2007
        • 210

        #4
        with wizard tool you donot need to create child forms. Then once the user inputs all the data you can insert the data to the database. Regarding getting the parent id you can use stored procedure to do the entire work at once or just break down the sequence of insert .

        Comment

        • gmiotke
          New Member
          • Mar 2010
          • 4

          #5
          Is there a way to set the value of a field in a future step based on a retunred database field that was created on step one?

          Comment

          • semomaniz
            Recognized Expert New Member
            • Oct 2007
            • 210

            #6
            All you have to do is retrieve the value from the database and use it or assign it to a hidden field for further processing

            Comment

            • gmiotke
              New Member
              • Mar 2010
              • 4

              #7
              I have a potential problem. How can I get the ID field for this user and only this user when they have not logged in. Is there something unique to this transaction that I can put into the parent record? Without this I am not sure how I could get the correct parent ID field out of the dB

              Comment

              • Frinavale
                Recognized Expert Expert
                • Oct 2006
                • 9749

                #8
                By the sounds of it, you don't need to write anything to the database until you're finished the process. You can pass data between pages by storing it in Session, using cookies etc.

                If you decide to use the Wizard Web Server Control the you won't even have to pass information between pages...it'll all be on one page and you can store the information in ViewState if you want to.

                You'll want to update the database once the user has finished the process...it doesn't make sense to update it before the user has finished the process.

                -Frinny

                Comment

                Working...