You are not logged in.
Pages: 1
hi, is it possible from a script to read cfg files? mail.cfg for instance
also, is it possible to include other scripts code in a script?
Offline
Hi unsi_2,
yes, you can read the lostpassword.email.text property of the security/notifications.cf file like this:
import net.datenwerke.rs.utils.config.ConfigService;
import org.apache.commons.configuration.Configuration;
ConfigService configService = GLOBALS.getRsService(ConfigService.class);
Configuration config = configService.getConfigFailsafe("security/notifications.cf");
String mailTemplate = config.getString("lostpassword.email.text", "default text");
For calling scripts from other scripts, pls take a look here: https://reportserver.net/en/guides/scri … m-Scripts/
Regards,
Eduardo
Offline
many thanks! great help
Offline
Pages: 1