Calling another form

  • Thread starter Thread starter John
  • Start date Start date
If I use Response.Redirect("page2", false) to redirect to page 2 from this
page, how can I tell page 2 to return to this page when done?

Thanks

Regards
 
If I use Response.Redirect("page2", false) to redirect to page 2 from
this page, how can I tell page 2 to return to this page when done?

On page 2, you use reponse.redirect back to the original page...

You may need to pass a variable to page1 to tell page1 that you've already
processed page2 and not to redirect again.
 
What if several pages call page 2 for validation? Should I send the name of
the calling page in the call somehow or is there an automatic method to
determine the calling page?

Thanks

Regards
 
What if several pages call page 2 for validation? Should I send the
name of the calling page in the call somehow or is there an automatic
method to determine the calling page?

You can use the server variable HTTP_REFERER to find out which page called
the current page.

However, if you're creating a page just for validation it may make more
sense to create a validation class rather than a validation page. With a
validation class, you can call it within a page's validation event without
redirecting.
 
Back
Top