Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
datanibbler
Champion
Champion

Variables combining data from script and from GUI

Hi,

I know I can define variables in the script so that they are populated dynamically on the GUI, based on the user's selections.

But now I have to combine both ways:

- I have to assemble an email_distribution_list from names in an Excel_file;

- These lists go into a button to trigger an email (like a URL); That URL can take some information for the header - and that piece of
    information is based on the user's selections, thus it can be populated only on the GUI.

Sounds easy - but I cannot get it to work.

The code to define variables for populating with values from the GUI is like this

>> SET v_myvariable = = Getfieldselections(field1); <<

A URL for an email to be triggered by a button on the GUI has to look like this

>> 'mailto:firstname.lastname@domain.com?subject=bla bla blub;' <<

The trick is, the email can also take some information from the app, thus it can look like this

>> 'mailto:firstname.lastname@domain.com?subject=bla bla blub Info ' & Info; << (where Info is the name of a field and because of the user's selections, there is only one value to that field)

<=> I cannot seem to be able to combine these in the script.

I am trying to do this, first defining the GUI_variable

- SET v_myvar = = Info;

... and then appending this to my email_distribution_list

- LET v_email_list = 'mailto:[valid_and_tested_list]' & '?subject=bla bla blub ; Info ' & Info & ';'

Can anyone understand what's wrong with this syntax? I guess it's to do with the '=' that I need for any variables that are supposed to be populated on the GUI; But I don't know how to get rid of this.

Thanks a lot!

Best regards,

DataNibbler

Labels (1)
1 Reply
datanibbler
Champion
Champion
Author

Hmmm ... I have found a workaround insofar as some more code can be added to this on the GUI;

I'd still like to know how this could be done ...