In my module, I use element "Create report with database" on Axon.ivy 5.1. I don't use "designRepository" in birt.properties so that I can define my own absolutely path. Like this:

  1. Disable the configuration in birt.properties:

    "#designRepository=C:/MyReportRepo/"

  2. declare the path to report design files (.rptdesign) in my code:

    in.templateFilename = "E:/_vision/CONFIG/myReportDesign"

I am facing a problem when I've tried to integrate my module with another one which needs to define "designRepository" in birt.properties. It means that the another module needs to activate the configuration, like this:

designRepository=C:/MyReportRepo/

In this case, I got an exception:

EngineException: The design file C:/MyReportRepo//E:/_vision/CONFIG/myReportDesign.rptdesign can not be found.

Until now, I've tried to find the way to get and modify the defined path. I mean I would try to ignore this "C:/MyReportRepo//" when it is activated, so that hope both mentioned modules can work.

I also try using element "Create dynamic report" instead but the demo doesn't work. I referenced this link: https://guidelines.soreco.ch/projects/guides/wiki/BIRT

Any help will be greatly appreciated!

asked 17.12.2014 at 11:37

nvhuong's gravatar image

nvhuong
120267
accept rate: 66%


The birt extension is open source and is shared on ivySupplements@sourceforge. Your code could work with a very simple modification in IvyBirtReportService.getReportDesign(String).

/**
* Return the absolute path of the report design. If a design repository
* exists, then the path will be calculated, otherwise the report design
* contains already the absolute path
* @param reportDesign
* @return
*/
private String getReportDesign(String reportDesign){
  if(designRepository != null && !designRepository.equals("")){
    return designRepository + "/" + reportDesign + BIRT_REPORT_SUFFIX;
  }else{
    return reportDesign + BIRT_REPORT_SUFFIX;
  }
}

I suggest that you enhance the code for your needs. And if its a save implementation that could work for the whole community: share it or else fork it.

link

answered 19.12.2014 at 10:45

Reguel%20Wermelinger's gravatar image

Reguel Werme... ♦♦
7.9k11549
accept rate: 68%

edited 19.12.2014 at 10:47

Hello Reguel

Thanks for your suggestion.

(22.12.2014 at 03:04) nvhuong nvhuong's gravatar image

sorry. it's impossible.

link

answered 18.12.2014 at 02:20

trungdv's gravatar image

trungdv
4958298103
accept rate: 52%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "Title")
  • image?![alt text](/path/img.jpg "Title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×6

Asked: 17.12.2014 at 11:37

Seen: 1,290 times

Last updated: 22.12.2014 at 03:04