How to open a page outside an iframe?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

When I click on a linkbutton of a datagrid on a web form I open another web
form on the same page within an iframe. The page within the iframe has a
datagrid also and when I click on a linkbutton in that datagrid I redirect to
another webform.

The problem I'm having is that this last webform opens within the iframe but
I want it to open on another page outside the iframe.

Any ideas will be appreciated.
 
you would have to link page inside iframe to post back to the container
page.
this can be done through using parent property in javascript, but
beaware that if pages are in different domains, this would through a
security warning
 
Hello,

When I click on a linkbutton of a datagrid on a web form I open another web
form on the same page within an iframe. The page within the iframe has a
datagrid also and when I click on a linkbutton in that datagrid I redirect to
another webform.

The problem I'm having is that this last webform opens within the iframe but
I want it to open on another page outside the iframe.

Any ideas will be appreciated.
Not possible with IFRAME, I am afraid. However, in your primary page you
could use a form, or the location object, and you have to set the target
to _top.
 
Thanks but I'm afraid I'm new to web development. My html looks like this and
ButtonColumn does not support an onclick event. I don't know how to proceed.

<form ...>
<asp:DataGrid ...>
<Columns>
<asp:BoundColumn ...></asp:BoundColumn>
<asp:BoundColumn ...></asp:BoundColumn>
<asp:ButtonColumn Text="View Visit"
CommandName="visit"></asp:ButtonColumn>
</Columns>
</asp:DataGrid>
</form>
 
Sorry I don't understand. Can you elaborate?

intrader said:
Not possible with IFRAME, I am afraid. However, in your primary page you
could use a form, or the location object, and you have to set the target
to _top.
 

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

Similar Threads

iframe question 2
prevent iframe reload at postback 1
Alternet to iframe?? 6
IFRAME containing ASP.NET Site within a Classic ASP Page 1
iframes 2
Hiding a parent Iframe from asp.net 2
Iframe problem 2
iframe 3

Back
Top