PDF Report target=BLANK is not opening a new tab

I have created a PDF report with Jasper and I am opening the report in my browser and when I click on the link embedded in the report that I thought would open the link in a new tab it actually loads the link right on the tab I am on. I was hoping the target of Blank would cause the link to load in another tab (I tested this in Chrome on the Mac and IE10 on Windows 7).

From what I read in the Jasper documentation, I thought BLANK would open a new tab in my browser.

http://jasperreports.sourceforge.net/sample.reference/hyperlink/

Here is my code:

   <textField hyperlinkType="Reference" hyperlinkTarget="Blank">
                <reportElement x="0" y="5" width="100" height="15"/>
                <textFieldExpression class="java.lang.String">"Click here"</textFieldExpression>
                <hyperlinkReferenceExpression>"http://www.google.com"</hyperlinkReferenceExpression>
   </textField>  

Has anyone had any luck getting this to work in PDF generated with JasperReports?

Any help would be appreciatied.

Thanks.

richddean's picture
Joined: Nov 11 2011 - 11:03am
Last seen: 8 years 1 week ago

1 Answer:

The answer is written in the old ticket in the Tracker.

http://community.jaspersoft.com/jasperreports-library/issues/2506

hozawa's picture
176897
Joined: Apr 24 2010 - 4:31pm
Last seen: 3 years 11 months ago

So it looks like it is not possible with a PDF generated document that is opened in the browser to open a link in a new tab.

Thanks for the feed back.

richddean - 9 years 3 months ago
Feedback