plugins.jasperPluginRMI.reportDirectory in Velocity

Hi,

How do we get the value in the “velocityreport.reportfolder”? In Jasper, I can use plugins.jasperPluginRMI.reportDirectory to get the report folder. How do I do it in velocity? Thanks!

You don’t ‘get’ the value, you set it!

Go to your server’s admin page (http://yourserver:port/servoy-admin), then in the plugins page you should see a few fields for the velocity report plugin, this is where you set the velocityreport.reportfolder (it should be a path relative to the server - and if you don’t the plugin will use the java.lang,System.getProperty(‘user.dir’) of the user that has launched the server).

Then you can use paths relative to this folder when you want to use a template, for example ‘/template1/mytemplate.html’ will point to a file located in the subfolder ‘template1’ of the folder you have set in the admin page.

Hope this helps,

Hi Patrick,

Yes, I know it is set in the server. I guess my question was not clear.

How do you get the path that was set in the application server lilke just like the property “plugins.jasperPluginRMI.reportDirectory” which returns the path taken from the server?

erikd:
Hi Patrick,

Yes, I know it is set in the server. I guess my question was not clear.

How do you get the path that was set in the application server lilke just like the property “plugins.jasperPluginRMI.reportDirectory” which returns the path taken from the server?

You don’t :)
But if you can explain to me why you need it I can add it to the next release.

ptalbot:

erikd:
Hi Patrick,

Yes, I know it is set in the server. I guess my question was not clear.

How do you get the path that was set in the application server lilke just like the property “plugins.jasperPluginRMI.reportDirectory” which returns the path taken from the server?

You don’t :)
But if you can explain to me why you need it I can add it to the next release.

This method will be helpful in displaying the report directory folder in the application’s settings dialog. Or it can also be used in debugging purposes.

thanks.

The application’s settings dialog? You will not be able to change that at runtime!
I can give you a get method but not a set method.

ptalbot:
The application’s settings dialog? You will not be able to change that at runtime!
I can give you a get method but not a set method.

I am not talking about setting it. I am talking only about getting it. Thanks.

Could you open an issue to the ServoyForge project so that I can have that in my todo list for next release?

Thanks!

Done. Thanks