On buttonSave click after saving the record successfully ,I want to show “Save successfully “ message on a label on a page for few seconds and then reload the page. Thanks in Advance
+1
A:
You can add a META refresh tag:
<meta http-equiv="refresh" content="5;url=SomeURL">
SLaks
2010-07-27 15:22:27
Shoban - Read my question carefully, before making any comments
2010-07-27 18:25:54
A:
I don't know about ASP, yet I'll tell you a simple idea, you can use timers, and add a trigger to the timer as when the timer is out, the trigger is fired. Hope I have helped you ...
sikas
2010-07-27 15:30:44
A:
You can do this using the 'meta' tag. This will reload the page after 3 seconds:
<meta http-equiv="refresh" content="3">
To do this in code, you can do something like this in your submit event (C# syntax but it should be easy enough to understand):
HtmlMeta meta = new HtmlMeta()
{
HttpEquiv = "refresh",
Content = "3"
};
Page.Header.Controls.Add(meta);
For this to work, you need to have a <head runat="server">
on the page.
richeym
2010-07-27 15:30:58
A:
You can show a nice overlay busy message.
The Mark-up part:
$(function() { // when document has loaded
($.unblockUI); //unlock UI
//Show busy message on click event and disable UI
$('#btnHelloWorld').click(function() {
$.blockUI({ message: '<h4><img src="busy.gif" />Please wait...</h4>' });
});
});
<asp:Button ID="btnHelloWorld" runat="server" Text="Hello World" /><br/>
The Code behind:
Protected Sub btnHelloWorld_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btnHelloWorld.Click
Label1.Text = "Hello World"
Threading.Thread.Sleep(5000)
End Sub
Check out jQuery BlockUI Plugin
Angkor Wat
2010-08-04 21:40:06