Print Page | Close Window

Adding Info

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: ASP.NET Discussion
Forum Description: Discussion and chat on ASP.NET related topics.
URL: https://forums.webwiz.net/forum_posts.asp?TID=14669
Printed Date: 29 March 2026 at 9:21am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Adding Info
Posted By: Misty
Subject: Adding Info
Date Posted: 13 April 2005 at 2:39am

I am having a problem with an ASP.Net application that I built at http://www.bethedenmbc.org/prayerrequests.aspx - http://www.bethedenmbc.org/prayerrequests.aspx . This web page uses a data list. A person fills out a form and then is redirected to a page that shows the records including the information that the person entered. The problem is the person has to refresh the web page to see his/her information. I want the person's information to show up on prayerrequests.aspx immediately after the person has been redirected from the form.

How do I solve this problem?



Replies:
Posted By: Mart
Date Posted: 13 April 2005 at 2:42am
Just use Response.Redirect(Request.Url.ToString()) after adding the record


Posted By: Misty
Date Posted: 13 April 2005 at 2:49am
I actually used Response.Redirect("PrayerRequests.aspx") in the web page that uses the form. It redirects to the page, but the new information is not displayed unless you refresh the web page.
 
My code for this was included in the following sub procedure:
 
        '---------------------------------------------
        ' name: DisplayResults()
        '---------------------------------------------
        Sub DisplayResults()
                 Dim strDisplay as string
                 'We don't want to show the user the form again
                 frmPrayerRequests.Visible = False
                 'Show the new page heading for the postback page
                 lblResultsTitle.Visible = True
                 lblResultsTitle.Text = "<h3>Thank you for adding your prayer request! </h3>"
                
                
                 Response.Redirect("PrayerRequests.aspx")  
        End Sub
 
Page_Load() sub procedure calls DisplayResults()



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net