Jump to content
We've recently updated our Privacy Statement, available here ×

Hyperlink reference doesn't work in iPad


juan.alonso
Go to solution Solved by juan.alonso,

Recommended Posts

Hi everyone,
I've created a report with a external hyperlink, similar to samples/hyperlink/reports/HyperlinkReport.jrxml. When I export the report to pdf the link works fine in Pc but doesn't work in iPad. I've edited the pdf with Adobe Professional and I've observed that link is generated with a javascript code not as external link. This is the javascript injected by JasperReports in the hyperlink:

if (app.viewerVersion < 7){    this.getURL("http://www.google.com");} else {    app.launchURL("http://www.google.com", true);};

The jrxml code is:

<textField hyperlinkType="Reference" hyperlinkTarget="Blank">         <reportElement x="5" y="95" width="200" height="15" uuid="773ef7f6-735d-47f7-8b16-d8136c5da1d3"/>         <textFieldExpression><![CDATA["  >> Click here to go to www.google.com"]]></textFieldExpression>         <hyperlinkReferenceExpression><![CDATA["http://www.google.com"]]></hyperlinkReferenceExpression> </textField>

Please someone who can help me.
 
Thanks.
 
Juan

 

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

  • Solution

The solution was simple:

I've removed the hyperlinkTarget atribute and fixed!!

<textField hyperlinkType="Reference">
<reportElement x="5" y="95" width="200" height="15" uuid="773ef7f6-735d-47f7-8b16-d8136c5da1d3"/>
<textFieldExpression><![CDATA[" >> Click here to go to www.google.com"]]></textFieldExpression>
<hyperlinkReferenceExpression><![CDATA["http://www.google.com"]]></hyperlinkReferenceExpression>
</textField>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...