Is it possible to mimic the unmask checkbox functionality for passwords in a BitRock panel? I’d like the user to have the option to either mask the password or show it in plain text. Can you suggest any other solutions to support this behavior?
Hi MarkSDM,
Unfortunately, InstallBuilder doesn't support currently a native option to unmask/mask the value of a passwordParameter. However, you can follow the next example to achieve that:
<parameterGroup> <name>password_group</name> <explanation></explanation> <value></value> <default></default> <orientation>horizontal</orientation> <parameterList> <passwordParameter> <name>password_entry</name> <description></description> <explanation></explanation> <value>${password}</value> <default></default> <allowEmptyValue>1</allowEmptyValue> <askForConfirmation>0</askForConfirmation> <descriptionRetype></descriptionRetype> <width>40</width> <postShowPageActionList> <setInstallerVariable name= or ' password or ' value= or ' ${password_entry} or ' /> <setInstallerVariable name= or ' password_plain or ' value= or ' ${password_entry} or ' /> </postShowPageActionList> </passwordParameter> <stringParameter> <name>password_plain</name> <description></description> <explanation></explanation> <value>${password}</value> <default></default> <allowEmptyValue>1</allowEmptyValue> <ask>0</ask> <width>40</width> <postShowPageActionList> <setInstallerVariable name= or ' password or ' value= or ' ${password_plain} or ' /> <setInstallerVariable name= or ' password_entry or ' value= or ' ${password_plain} or ' /> </postShowPageActionList> </stringParameter> <stringParameter> <name>password</name> <description></description> <explanation></explanation> <value></value> <default></default> <allowEmptyValue>1</allowEmptyValue> <ask>0</ask> <width>40</width> </stringParameter> <linkParameter> <name>update</name> <description>Show</description> <explanation></explanation> <displayStyle>button</displayStyle> <clickedActionList> <if> <actionList> <setInstallerVariable name= or ' parameter(password_group).parameter(update).description or ' value= or ' Hide or ' /> <setInstallerVariable name= or ' parameter(password_group).parameter(password_entry).ask or ' value= or ' 0 or ' /> <setInstallerVariable name= or ' parameter(password_group).parameter(password_plain).ask or ' value= or ' 1 or ' /> </actionList> <conditionRuleList> <isTrue value= or ' ${parameter(password_group).parameter(password_entry).ask} or ' /> </conditionRuleList> <elseActionList> <setInstallerVariable name= or ' parameter(password_group).parameter(update).description or ' value= or ' Show or ' /> <setInstallerVariable name= or ' parameter(password_group).parameter(password_entry).ask or ' value= or ' 1 or ' /> <setInstallerVariable name= or ' parameter(password_group).parameter(password_plain).ask or ' value= or ' 0 or ' /> </elseActionList> </if> <updatePage/> </clickedActionList> </linkParameter> </parameterList> </parameterGroup>
I also want this functionality. I tried your code snippet, after much fixing of bad characters in it, and it fails. I get the following error message.
----------------------------------------------
There has been an error.
Unknown element password_group
The application will exit now.
----------------------------------------------
Attached is the fixed XML code.
I figured out my issue, it was under a component so I had to add the $component(myComp) selector.