Refresh a parent window???

H

Helixpoint

I have a frameset. left and main. Inside the main frame I have a IFRAME. I
need to refresh the main frame when I post a form inside the IFRAME. I am
trying the code below with no luck??


Private Sub addMachine_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles addMachine.Click

Dim sScript As New System.Text.StringBuilder
sScript.Append("<SCRIPT language=""javascript"">" & vbCrLf)
sScript.Append("parent.window.opener.location =
parent.window.opener.location;" & vbCrLf)
sScript.Append("</SCRIPT>" & vbCrLf)
RegisterClientScriptBlock("ForceDefaultToScript", sScript.ToString)
End Sub


--

______________________
David Fetrow
HelixPoint LLC.
http://www.helixpoint.com
(e-mail address removed)

Interested in Affordable Email Marketing?
Check out the HelixMailer at http://www.helixpoint.com/helixmailer.asp
If you are interested in becoming a Reseller of HelixPoint products, contact
(e-mail address removed)
______________________
 
V

Vidar Petursson

Hi

If you want to refresh the whole frameset then this is ok...
If you only want to refresh the frame/document the iframe is located in

parent.location.href = "pagetogo.aspx";
Or
parent.location.reload(true);


--
Best Regards
Vidar Petursson
==============================
Microsoft Internet Client & Controls MVP
==============================
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top