Hi,
I manage to open a PDF file in an <IFRAME> by "clicking" on an HyperLink
with:
HyperLink.NavigateURL = "file:///C:\file.pdf"
HyperLink.Target = "iframename"
The question is... How can I do the same thing by "clicking" on a
button'
I searched in the System.Web.UI.HtmlControls collection and I can't find
the IFRAME object...
Any ideas?
Thanks in advance
CCAn IFRAME is simply HTML in a Page:
<iframe src ="/something.aspx"></iframe>
Add a runat=server to it, and an HtmlGeneric Control behind it, if you want
to manipulate it programmatically.
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
<carlos.cruz@.algeco.pt> wrote in message
news:ecdJl6kFEHA.3252@.TK2MSFTNGP11.phx.gbl...
> Hi,
> I manage to open a PDF file in an <IFRAME> by "clicking" on an HyperLink
> with:
> HyperLink.NavigateURL = "file:///C:\file.pdf"
> HyperLink.Target = "iframename"
> The question is... How can I do the same thing by "clicking" on a
> button'
> I searched in the System.Web.UI.HtmlControls collection and I can't find
> the IFRAME object...
> Any ideas?
> Thanks in advance
> CC
Hi,
I'm sorry but I don't undertand what you mean by putting a generic html
control behind the iframe. Could you be more specific?
Thanks
CC
Every Control (that is part of the Page definition) in the Page Template has
a corresponding object declaration in the CodeBehind class. In this case,
you would have to add it yourself. What software are you using to develop
your app?
HTH,
Kevin Spencer
.Net Developer
Microsoft MVP
Big things are made up
of lots of little things.
<carlos.cruz@.algeco.pt> wrote in message
news:ub13YbmFEHA.3448@.TK2MSFTNGP09.phx.gbl...
> Hi,
> I'm sorry but I don't undertand what you mean by putting a generic html
> control behind the iframe. Could you be more specific?
> Thanks
> CC
Tuesday, March 13, 2012
Targeting an <IFRAME> in code
Labels:
asp,
clicking,
code,
file,
hyperlink,
hyperlinkwithhyperlink,
ltiframegt,
manage,
navigateurl,
net,
pdf,
target,
targeting
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment