Install4j:如何在启动器的Java调用中指定密码值 [英] Install4j: how to specify a password value in Java Invocation of Launcher

查看:215
本文介绍了Install4j:如何在启动器的Java调用中指定密码值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Install4j中,我有一个表单可以让用户配置登录名/密码(变量名:loginpassword)

In Install4j, I have a form to let the user configure a login/password (with the variable names: login and password)

然后,我想使用Java Invocation Launcher中的登录名/密码值创建启动器.

Then I want to create a launcher using the login/password values in Java Invocation Launcher.

请参见下面的屏幕截图.

See the screenshot below.

  1. 安装后如何调试以查看这些参数的值?
  2. ${installer:password}确实是用户输入的值吗?
  1. How can I debug to see the value of these arguments after the installation ?
  2. The ${installer:password} is really the entered value by the user ?

推荐答案

您可能使用密码字段"表单组件.密码字段组件的绑定变量未写入响应文件.这就是为什么发射器不可用的原因.

You probably use a "Password field" form component. The bound variable for a password field component is not written to the response file. That's why it's not available for the launchers.

为另一个变量(即"clearPassword")添加设置变量"操作,将脚本设置为

Add a "Set a variable" action for another variable, i.e. "clearPassword", set the script to

context.getVariable("password")

,然后选择该操作的注册响应文件"属性.然后,您可以在启动器参数中使用${installer:clearPassword}.

and select the "Register for response file" property of that action. Then you can use ${installer:clearPassword} in the launcher arguments.

还有一个错字,应该是${installer:login}而不是{installer:login}.

Also you have a typo, it should be ${installer:login} and not {installer:login}.

这篇关于Install4j:如何在启动器的Java调用中指定密码值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆