How to open a webform in a iframe when with vb.net code

  • Thread starter Thread starter jonny
  • Start date Start date
J

jonny

I have a webform with a iframe on it. When I click a button I want to
show a webform called frmExample inside the iframe. I am having
trouble with the code to call a form inside the iframe.

Here is what I have so far...

Protected Sub Button1_Click(ByVal sender As Object, ByVal e As
EventArgs) Handles Button1.Click
iFrameReport.Visible = True
iFrameReport.Attributes("src") = frmExample.aspx
End Sub

(I am going to list this question in the VB.net group also because I
am not sure which group is best for this question)
 
I have a webform with a iframe on it. When I click a button I want to
show a webform called frmExample inside the iframe. I am having
trouble with the code to call a form inside the iframe.

Here is what I have so far...

Protected Sub Button1_Click(ByVal sender As Object, ByVal e As
EventArgs) Handles Button1.Click
        iFrameReport.Visible = True
        iFrameReport.Attributes("src") = frmExample.aspx
    End Sub

(I am going to list this question in the VB.net group also because I
am not sure which group is best for this question)

Never mind I figured it out.
 
Whicho doesn't compile as frmExample.aspx is not an identifier.

Have you tried :

iFrameReport.Attributes("src") = "frmExample.aspx"

instead ? Also if the frmExample.aspx is not in the same directory you'll
have to include the correct path to this page...

--
Patrice

"jonny" <[email protected]> a écrit dans le message de groupe de
discussion :
(e-mail address removed)...

Thank you.
 
Back
Top