VB Macro Loop to Create Field Trigger Set Variable Action
This has been created with help from multiple questions and answers on the forum and some extra vb searches. Hopefully, others will be able to adapt this for other purposes as required.
I needed to create set variable actions as field triggers for a complex QVD creator user interface I have made.
I wanted to be able to have the creation and deletion of these triggers automated due to the large number of fields.
I also wanted to have both OnChange and OnSelect triggers for these fields.
The variable values are the possible values of the fields separated by hashes. This is used by my QVD creator load script (that's for another day).
My real field names have been replaced with generic text for this posting. In this example the field names I am using have a similar naming structure of LIST_GROUP1_NAME1. The variables have a similar naming structure of vd_SELECTIONS_GROUP1_NAME1. I wanted to be able to have multiple arrays to loop through these levels.