Jump to content
Software FX Community

Getting Invalid License message when exporting charts ...


Recommended Posts


We are using Chartfx 7.0 for java here at
the census bureau. As long as we use the renderControl() method, the chart
renders fine and we are able to access the charts via the AJAX

However, there are use cases where we need to generate the chart
as an image and embed them in PDF reports. We are trying to use the
exportChart() method for this and trying to create a PNG image as shown in the code example below ....

However, the image produced by this method shows
"Invalid ChartFX licenese" message.

Below is the source sample for

private File getChartFile(ChartData chartData, FileFormat
fileFormat, Gallery gallery, AxisFormat axisFormat, int width, int height)
    ChartServer chart1 = new ChartServer();    

Feeds in the chart data to chart server
    File tempFile = null;
    try {
tempFile = File.createTempFile("euschartfx", ".cfx");
  FileOutputStream ostream = new FileOutputStream(tempFile);
chart1.exportChart(fileFormat, ostream);

    } catch (IOException e)
    return tempFile;  

What are we
missing here?


-- Vishal
IBM / Census Bureau
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...