Reputation: 2227
I am trying to register a customer with multiple friends and save all the data.
Currently using the ASP .Net Wizard control:
Stage 1 - Customer enters their details (name, add etc). When they click Next i save the Cust data. Stage 2 - Once the details have been saved in stage 1 the customer now fills in a couple of textboxes and clicks save to save each friend. Stage 3 - They click Finish and this the writes back the values in a Many to Many table to link the customer and friends table.
As you can tell the above has a few loop holes. If customer has entered the wrong results in stage 1 then they cant go back to change it if i allow this option then it would insert another new row.
If i save all the data in Stage 3 then i cant relate the friends saved in Stage 2 to the customer row.
Could anyone advise of other ways to accomplish this as it seems the Wizard control may not be fit for this purpose (unless im using it incorrectly then i would like to know how and where)?
Upvotes: 0
Views: 167
Reputation: 2205
You will need to add the information from page 1 in some session variable, then when you submit the page 2, page 3 will take the information from the session variables and from page2 and do its job
Method 2
You need to store the information of page 1 in some hidden element in page 2. In this way, when you submit page 2, then all the data will be there to process in page 3.
Upvotes: 1