Click here to Skip to main content
15,921,660 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Avoid Duplicate record insertion on page refresh(F5) Pin
amitamit09916-Feb-10 1:52
amitamit09916-Feb-10 1:52 
GeneralRe: Avoid Duplicate record insertion on page refresh(F5) Pin
Anurag Gandhi16-Feb-10 2:56
professionalAnurag Gandhi16-Feb-10 2:56 
AnswerRe: Avoid Duplicate record insertion on page refresh(F5) Pin
JustWorking16-Feb-10 1:30
JustWorking16-Feb-10 1:30 
AnswerRe: Avoid Duplicate record insertion on page refresh(F5) Pin
Rhys Jacob16-Feb-10 1:35
Rhys Jacob16-Feb-10 1:35 
AnswerRe: Avoid Duplicate record insertion on page refresh(F5) Pin
Brij16-Feb-10 1:40
mentorBrij16-Feb-10 1:40 
GeneralRe: Avoid Duplicate record insertion on page refresh(F5) Pin
Anurag Gandhi16-Feb-10 1:50
professionalAnurag Gandhi16-Feb-10 1:50 
GeneralRe: Avoid Duplicate record insertion on page refresh(F5) Pin
Brij16-Feb-10 2:04
mentorBrij16-Feb-10 2:04 
AnswerRe: Avoid Duplicate record insertion on page refresh(F5) Pin
Dinesh Mani16-Feb-10 2:33
Dinesh Mani16-Feb-10 2:33 
There is no straight forward way to avoid this without refreshing the page. The simplest way to go is to use Server.Transfer or Response.Redirect from the server after completing the save.

Since you wish to display a message then you can do it in either of the two ways.
1. Simply put a button to refresh the data above the data section and hope that users use this instead of the browsers' refresh button [F5]. In most cases, the users would use this instead of F5. If its a intranet application then you can even educate your users on the same. You could also put a message next to the button telling them to use this rather than F5.

2. After you complete the save and give the message, just push a client script that would refresh the page using say "window.self.location=" after waiting for a specified time say 5 seconds. That way, your message would be visible for 5 seconds and the postback would be cleared.
GeneralRe: Avoid Duplicate record insertion on page refresh(F5) Pin
amitamit09916-Feb-10 3:00
amitamit09916-Feb-10 3:00 
AnswerRe: Avoid Duplicate record insertion on page refresh(F5) Pin
bgates197016-Feb-10 4:55
bgates197016-Feb-10 4:55 
AnswerRe: Avoid Duplicate record insertion on page refresh(F5) [modified] Pin
Member 103390716-Feb-10 9:29
Member 103390716-Feb-10 9:29 
GeneralRe: Avoid Duplicate record insertion on page refresh(F5) Pin
amitamit09916-Feb-10 19:03
amitamit09916-Feb-10 19:03 
Questionbind Checkboxes Pin
m@dhu15-Feb-10 22:03
m@dhu15-Feb-10 22:03 
AnswerRe: bind Checkboxes Pin
Brij15-Feb-10 22:16
mentorBrij15-Feb-10 22:16 
AnswerRe: bind Checkboxes Pin
Dinesh Mani15-Feb-10 22:17
Dinesh Mani15-Feb-10 22:17 
AnswerRe: bind Checkboxes Pin
keyur satyadev15-Feb-10 22:52
keyur satyadev15-Feb-10 22:52 
QuestionWeb Deployment error for WebUserControl event [modified] Pin
K V Sekhar15-Feb-10 21:29
K V Sekhar15-Feb-10 21:29 
AnswerRe: Web Deployment error for WebUserControl event Pin
Dinesh Mani15-Feb-10 21:47
Dinesh Mani15-Feb-10 21:47 
GeneralRe: Web Deployment error for WebUserControl event Pin
K V Sekhar15-Feb-10 21:55
K V Sekhar15-Feb-10 21:55 
GeneralRe: Web Deployment error for WebUserControl event Pin
Dinesh Mani15-Feb-10 22:07
Dinesh Mani15-Feb-10 22:07 
GeneralRe: Web Deployment error for WebUserControl event Pin
K V Sekhar15-Feb-10 22:58
K V Sekhar15-Feb-10 22:58 
GeneralRe: Web Deployment error for WebUserControl event [modified] Pin
Dinesh Mani15-Feb-10 23:03
Dinesh Mani15-Feb-10 23:03 
GeneralRe: Web Deployment error for WebUserControl event Pin
K V Sekhar16-Feb-10 2:04
K V Sekhar16-Feb-10 2:04 
GeneralRe: Web Deployment error for WebUserControl event Pin
Dinesh Mani16-Feb-10 2:24
Dinesh Mani16-Feb-10 2:24 
GeneralRe: Web Deployment error for WebUserControl event Pin
K V Sekhar16-Feb-10 3:17
K V Sekhar16-Feb-10 3:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.