469,964 Members | 1,656 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,964 developers. It's quick & easy.

How to create preview page before submitting

Hello everyone,

I am just barely two months old into learning asp.net and vb.net. Currently
I am working on a project to store customer database. I have a question about
creating a preview page:

I have a main page that uses forms to input customer information such as
name, contacts etc... Once all information is filled up, I would like to
preview it irst before submitting to the database. On the main page, there
should be a preview button which will pop-up another page that display all
the information that I have entered. This new pop-up preview page should have
a "Submit" and "Cancel" button. "Submit" button will then update the database
with the information entered from the main page.

How do I go about doing this, where should I store the temporary data before
actually updating the database? Thanks in advance.
Jan 16 '06 #1
2 4238
Sounds like you want to make a confirmation page.

i would have all my vars stored in page A then on click submit or whatever
button you have post that data to page B 9confirmation preview page).

Catch all the posted vars and set a load of text boxes on that preview page
to those caught vars but on this page have the text boxes read only.

At the bottom of the page have a 'is this right? ' or whatever and a final
submit button as you suggested. On clicking that submit button inside there
have your code to write the info to the db or whatever by using the values
of the text boxes.

Hope that makes sense.

"Syam" <Sy**@discussions.microsoft.com> wrote in message
news:D7**********************************@microsof t.com...
Hello everyone,

I am just barely two months old into learning asp.net and vb.net.
Currently
I am working on a project to store customer database. I have a question
about
creating a preview page:

I have a main page that uses forms to input customer information such as
name, contacts etc... Once all information is filled up, I would like to
preview it irst before submitting to the database. On the main page, there
should be a preview button which will pop-up another page that display all
the information that I have entered. This new pop-up preview page should
have
a "Submit" and "Cancel" button. "Submit" button will then update the
database
with the information entered from the main page.

How do I go about doing this, where should I store the temporary data
before
actually updating the database? Thanks in advance.

Jan 16 '06 #2
I agree with the first two replies. You can either pass your variables
through the variables mentioned by 'Spam Catcher' (my preference for this
being the Session variable) or you could pass the variables through a get /
post using the query string or form fields.

Another alternative that you may want to consider is that you don't actually
move pages when your user clicks submit.

Alongside where your form controls are, you could place labels that are
hidden initially. When the user clicks the submit button the label's .text
properties are set to the .text properties of their corresponding form
fields. The form fields could then be hidden and the labels unhidden.

Would allow you keep all this in one page instead of trying to come up with
consistent naming for your confirmation pages if there becomes more than one
(as is usually the case).

Just an idea.

Hope this helps.

--
Kurt Farrar
..NET Developer & Computer Enthusiast

"Syam" wrote:
Hello everyone,

I am just barely two months old into learning asp.net and vb.net. Currently
I am working on a project to store customer database. I have a question about
creating a preview page:

I have a main page that uses forms to input customer information such as
name, contacts etc... Once all information is filled up, I would like to
preview it irst before submitting to the database. On the main page, there
should be a preview button which will pop-up another page that display all
the information that I have entered. This new pop-up preview page should have
a "Submit" and "Cancel" button. "Submit" button will then update the database
with the information entered from the main page.

How do I go about doing this, where should I store the temporary data before
actually updating the database? Thanks in advance.

Jan 16 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Frank Millman | last post: by
reply views Thread by Lloyd Dupont | last post: by
9 posts views Thread by igotyourdotnet | last post: by
11 posts views Thread by =?Utf-8?B?UGV0ZXIgSw==?= | last post: by
1 post views Thread by rainxy | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.