Click here to Skip to main content
15,899,679 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: Refresh the page after data filled. Pin
amol1623-Feb-12 5:51
amol1623-Feb-12 5:51 
QuestionHow to Hide telerik:GridTemplateColumn on the ClientSide Pin
Vimalsoft(Pty) Ltd22-Feb-12 11:16
professionalVimalsoft(Pty) Ltd22-Feb-12 11:16 
AnswerRe: How to Hide telerik:GridTemplateColumn on the ClientSide Pin
R. Giskard Reventlov22-Feb-12 12:03
R. Giskard Reventlov22-Feb-12 12:03 
AnswerRe: How to Hide telerik:GridTemplateColumn on the ClientSide Pin
wizardzz23-Feb-12 10:42
wizardzz23-Feb-12 10:42 
GeneralRe: How to Hide telerik:GridTemplateColumn on the ClientSide Pin
Vimalsoft(Pty) Ltd23-Feb-12 18:04
professionalVimalsoft(Pty) Ltd23-Feb-12 18:04 
GeneralRe: How to Hide telerik:GridTemplateColumn on the ClientSide Pin
Vasudevan Deepak Kumar28-Feb-12 5:02
Vasudevan Deepak Kumar28-Feb-12 5:02 
GeneralRe: How to Hide telerik:GridTemplateColumn on the ClientSide Pin
Vimalsoft(Pty) Ltd28-Feb-12 5:45
professionalVimalsoft(Pty) Ltd28-Feb-12 5:45 
QuestionClose the Popup After Update Pin
Vimalsoft(Pty) Ltd22-Feb-12 11:02
professionalVimalsoft(Pty) Ltd22-Feb-12 11:02 
Good Morning All

I am Opening a Page as a Popup i am using Telerik WIndow which has similar functionality when opening a Popup like this

VB
function OpenPopUp(val_real, vis) {
           var myWidth = 0, myHeight = 0;
           if (typeof (window.innerWidth) == 'number') {
               //Non-IE
               myWidth = window.innerWidth;
               myHeight = window.innerHeight;
           } else if (document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) {
               //IE 6+ in 'standards compliant mode'
               myWidth = document.documentElement.clientWidth;
               myHeight = document.documentElement.clientHeight;
           } else if (document.body && (document.body.clientWidth || document.body.clientHeight)) {
               //IE 4 compatible
               myWidth = document.body.clientWidth;
               myHeight = document.body.clientHeight;
           }

           myWidth = myWidth / 2 - 150;
           myHeight = myHeight / 2 - 50;
           window.open('MyPage.aspx?Val=' + val_read, 'width=700,height=160,top=' + myHeight + ',left=' + myWidth)
           return false;

       }


this "myPage.aspx" page has a button that person some updates to the Database on the server side. This is opened as a popup and there is a grid below , so what i want to do after the Update to the Database has happened , i want to refresh the Grid, i have this code

VB
//This code is used to provide a reference to the radwindow "wrapper"
       function GetRadWindow() {
           var oWindow = null;
           if (window.radWindow) oWindow = window.radWindow; //Will work in Moz in all cases, including clasic dialog
           else if (window.frameElement.radWindow) oWindow = window.frameElement.radWindow; //IE (and Moz az well)
           return oWindow;
       }

       function CloseOnReload() {
           //alert("Dialog is about to close itself");
           GetRadWindow().close();
           RefreshParentPage();
       }

       function RefreshParentPage() {
           //alert("Dialog is about to reload parent page");
           GetRadWindow().BrowserWindow.location.reload();
       }

       function RedirectParentPage(newUrl) {
           alert("Dialog is about to redirect parent page to " + newUrl);
           GetRadWindow().BrowserWindow.document.location.href = newUrl;
       }

       function CallFunctionOnParentPage(fnName) {
           alert("Calling the function " + fnName + " defined on the parent page");
           var oWindow = GetRadWindow();
           if (oWindow.BrowserWindow[fnName] && typeof (oWindow.BrowserWindow[fnName]) == "function") {
               oWindow.BrowserWindow[fnName](oWindow);
           }
       }

       function RefreshParentPageWithoutWarning() {
           GetRadWindow().BrowserWindow.document.forms[0].submit();
       }


and on the server side i have this

VB
Response.Write("<Script>return RefreshParentPageWithoutWarning();</script>")

or

VB
SavetoDB(Values)

 ScriptManager.RegisterStartupScript(Page, Me.GetType(), "", "RefreshParentPageWithoutWarning()", True) 


My problem here is that it Refresh the page before it does a Database Update, and if it refreshes the page , the Database update ends up not being done.

Thanks
Vuyiswa Maseko,

Spoted in Daniweb-- Sorry to rant. I hate websites. They are just wierd. They don't behave like normal code.

C#/VB.NET/ASP.NET/SQL7/2000/2005/2008
http://www.vuyiswamaseko.com
vuyiswa[at]dotnetfunda.com
http://www.Dotnetfunda.com

AnswerRe: Close the Popup After Update Pin
R. Giskard Reventlov22-Feb-12 12:02
R. Giskard Reventlov22-Feb-12 12:02 
GeneralRe: Close the Popup After Update Pin
Vimalsoft(Pty) Ltd22-Feb-12 19:53
professionalVimalsoft(Pty) Ltd22-Feb-12 19:53 
QuestionError in deploying Asp.net web application with crystal report version 13 Pin
akosidandan22-Feb-12 4:14
akosidandan22-Feb-12 4:14 
AnswerRe: Error in deploying Asp.net web application with crystal report version 13 Pin
amargujrathi200623-Feb-12 18:26
amargujrathi200623-Feb-12 18:26 
QuestionASP.Net timeout Pin
berba22-Feb-12 1:39
berba22-Feb-12 1:39 
AnswerRe: ASP.Net timeout Pin
R. Giskard Reventlov22-Feb-12 12:07
R. Giskard Reventlov22-Feb-12 12:07 
AnswerRe: ASP.Net timeout Pin
thatraja22-Feb-12 19:54
professionalthatraja22-Feb-12 19:54 
QuestionUpdatePanel inside TemplateField Pin
Hanzaplast22-Feb-12 1:22
Hanzaplast22-Feb-12 1:22 
QuestionDatagrid - how to display an Image Pin
Bazzer74722-Feb-12 0:34
Bazzer74722-Feb-12 0:34 
Questioncreate subdomain in the asp.net Pin
apadana_198921-Feb-12 23:07
apadana_198921-Feb-12 23:07 
AnswerRe: create subdomain in the asp.net Pin
R. Giskard Reventlov22-Feb-12 12:08
R. Giskard Reventlov22-Feb-12 12:08 
QuestionAutomatically Printing Crystal Reports in ASP.NET Pin
saidfathi21-Feb-12 21:22
saidfathi21-Feb-12 21:22 
QuestionHow to remove CC and To in Outlook using Outlook Add in Template in .net Pin
palanirajan21-Feb-12 20:50
palanirajan21-Feb-12 20:50 
Questionsmtp: help how make emails deliver to inbox not junk box Pin
awedaonline21-Feb-12 0:43
awedaonline21-Feb-12 0:43 
AnswerRe: smtp: help how make emails deliver to inbox not junk box Pin
Richard MacCutchan21-Feb-12 1:32
mveRichard MacCutchan21-Feb-12 1:32 
Questionhelp how make emails deliver to inbox not junk box Pin
awedaonline21-Feb-12 0:42
awedaonline21-Feb-12 0:42 
AnswerRe: help how make emails deliver to inbox not junk box Pin
Richard MacCutchan21-Feb-12 1:31
mveRichard MacCutchan21-Feb-12 1:31 

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.