Usually when you are working with sharepoint, we have to create site programatically or any other operations programatically which will take more time than the usual.
This kind of srenarios rather than depending on the browser processing we can use the sharepoint beauty i.e SPLongRunOperation.
Here is the way to use this.
protected void btnSubmit_Click(object sender, EventArgs e) { using (SPLongOperation longOperation = new SPLongOperation(this.Page)) { longOperation.LeadingHTML = ""; longOperation.TrailingHTML = "Please wait your changes are processed"; longOperation.Begin(); string URL = SPContext.Current.Web.Url + "/Pages/OperationDone.aspx"; longOperation.End(URL); } }
This will give you a screen like below :
Thank you !!
No comments:
Post a Comment