Form Checkbox

User-to-User discussion about the PhraseExpress macro programming.
Post Reply
SemperX
Posts: 1
Joined: 21 Jun 19, 13:47

Form Checkbox

Post by SemperX » 21 Jun 19, 14:00

I currently have a form checkbox that is doing multiple iterative single pastes. I'd like it to append based on selection. Below is what I have:

{#formcheckbox -text Blank (Enter yourself) -vals "SkipValidation": "",}
{#formcheckbox -text InstancesMissing -vals "SkipValidation": "InstancesMissing",}
{#formcheckbox -text InstancesChanged -vals "SkipValidation": "InstancesChanged",}
{#formcheckbox -text MissingVersion -hint You only need to do this if you really mean to skip versions -vals "SkipValidation": "MissingVersion",}

Output is:
"SkipValidation": "InstancesMissing",
"SkipValidation": "InstancesChanged",
"SkipValidation": "MissingVersion",

but I'd like it to be:
"SkipValidation": "InstancesMissing,InstancesChanged,MissingVersion",

So I know
SkipValidation
is a constant and my variables are
InstancesMissing,InstancesChanged,MissingVersion
, but I'm not sure how to get them to append to one another like
"SkipValidation": "InstancesMissing,InstancesChanged,MissingVersion"
, based on a selection of Combo boxes.

Any help greatly appreciated.

Peter Stotz
PhraseExpress Expert
Posts: 778
Joined: 27 Feb 08, 15:07

Post by Peter Stotz » 21 Jun 19, 18:50

@SemperX
I'm not sure I understood your task ...
Example 1:
You can optionally select 'Missing Instances|Changed Instances|Missing Version' if you have previously selected 'Skip Validation'.

Code: Select all

{#forminput -text Skip Validation -type 2 -vals {#check -text {#forminput -text Skip Validating because ... -type 7 -items Instances missing|Instances changed|Missing Version -vals Instances missing|Instances changed|Missing Version -uncheckedvals || -enum ,  -lastenum , } -case ==  -output - -else Skip Validating: {#forminput -text Skip Validating because ... -type 7 -items Instances missing|Instances changed|Missing Version -vals Instances missing|Instances changed|Missing Version -uncheckedvals || -enum ,  -lastenum , }.}|-}
Example 2: Dynamic form

Code: Select all

{#form -text Validation -variablename Formulareinstellung}{#forminput -type 6 -items Validation|Skip Validation -vals | -def Validation -variablename Validating?}{#check -text {#forminput -text Skip Validation because .... -type 7 -items Instances missing|Instances changed|Missing Version -vals Instances missing|Instances changed|Missing Version -uncheckedvals || -enum ,  -lastenum ,  -visgroup Skip Validation -variablename Skip Validation} -case !=  -output Skip Validation: {#forminput -text Skip Validation because .... -type 7 -items Instances missing|Instances changed|Missing Version -vals Instances missing|Instances changed|Missing Version -uncheckedvals || -enum ,  -lastenum  ,   -visgroup Skip Validation -variablename Skip Validation}. -else -}
Peter
Windows 10 - PhraseExpress v14.0.145

Post Reply