开发者

How to change Required Disk space in install4j

I would appreciate if anyone 开发者_Go百科can help me with this

I am using install4j to create executable file, I need 2Gb of minimum space required , you can put this check ?.

I also want to check that machine should have 1.6X version of JDK installed, else I should terminate the installer. currently my installer is looking for JRE

thanks in advance

Sanjay


For the disk space check, add a "Run script" action to the "Startup" node of your installer and set its script to

if (SystemInfo.getFreeDiskSpace(context.getInstallationDirectory()) < 2000000000) {
    Util.showErrorMessage("You need at least 2 GB of free memory");
    return false;
}
return true;

Then, set the "Failure strategy" property of the action to "Quit on failure":

How to change Required Disk space in install4j

For the Java version check, go to General settings->Java version and set the minimum version to 1.6:

How to change Required Disk space in install4j

If the installer cannot find a 1.6 JRE with that minimum version, it will display a dialog with an appropriate message.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜