I have a link button that has an image, where if I click it, it needs to open a pdf file in a new tab/window. I added the PDF File on the my code folder. I’m not sure if this is right. But definitely I got an error. So maybe someone can point me to the right direction on how to do this properly.
This is the error I got: : error BC30456: ‘window’ is not a member of ‘ASP.sform_aspx’.
Below is my code:
<div style="float:right;">
<asp:LinkButton ID="btnMap" runat="server" style="text-decoration:none;"
OnClick="window.open('~ContentManagementZonesMap.pdf', '_blank', 'fullscreen=no');>
<asp:Image ID="Image1" runat="server" ImageUrl="~/Images/MapIcon.jpg" Height="40%" Width="40%" />
</asp:LinkButton>
</div>