Jump to content

How to create a hyperlink with API's


ldangelo

Recommended Posts

Hi all,

I'm wondering if someone can help me out...  I'm using the API's to generate jrxml.  I'm looking for an example of how you turn a text field into a hyperlink?  I've done the following:

 

        JRDesignExpression hlpe = new JRDesignExpression();
        hlpe.setValueClassName("java.lang.String");
        hlpe.setText("http://localhost;8080/orangeleap/");


        textField.setHyperlinkReferenceExpression(hlpe);
        textField.setHyperlinkType(JRHyperlink.HYPERLINK_TYPE_REFERENCE); //FIXME Should this be a parameter in the future?
 

But when I generate the report I get an error that says:

 

Class not set for hyperlink reference expression.Can anyone help me out?Thanks in advance,-LeoD

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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...