<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic variables within variables in load script in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936775#M323378</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everybody,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm in trouble with variables. I would like to load both chart expressions and set expressions in load script,&lt;/P&gt;&lt;P&gt;smth like this: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set vSet=2; // or&amp;nbsp; 1, or '&amp;lt;=3';&lt;/P&gt;&lt;P&gt;set vExpr=sum({$&amp;lt;klient ={$(vSet)}&amp;gt;} käive);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then the variable vSet should change it's value according to user selection- f.e.&amp;nbsp; klient=1, 2 , less than 3.&lt;/P&gt;&lt;P&gt;The variable change has to be made by button or other&amp;nbsp; action, not field selection. Variable vSet can if fact contain some kind of syntax as well, as its value will not be directly visible to user. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is - when i enter vExpr into Variables Overview window, and create the input box with vSet, it works as needed, i can enter 1,2 or &lt;SPAN style="font-size: 13.3333330154419px;"&gt; '&amp;lt;=3'.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;But when i load the same expr from load script, it evaluates $(vSet) at load time and writes f.e value 1 into the expression.&lt;/P&gt;&lt;P&gt;so i get &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;sum({$&amp;lt;klient ={1}&amp;gt;} käive) as vExpr. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;I tried all possible combinations of syntax but it gets evaluated, and later changes in vSet value from UI do not change the expression and chart. Can someone point me to the right direction, plz!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 31 Aug 2015 05:35:43 GMT</pubDate>
    <dc:creator />
    <dc:date>2015-08-31T05:35:43Z</dc:date>
    <item>
      <title>variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936775#M323378</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everybody,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm in trouble with variables. I would like to load both chart expressions and set expressions in load script,&lt;/P&gt;&lt;P&gt;smth like this: &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set vSet=2; // or&amp;nbsp; 1, or '&amp;lt;=3';&lt;/P&gt;&lt;P&gt;set vExpr=sum({$&amp;lt;klient ={$(vSet)}&amp;gt;} käive);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then the variable vSet should change it's value according to user selection- f.e.&amp;nbsp; klient=1, 2 , less than 3.&lt;/P&gt;&lt;P&gt;The variable change has to be made by button or other&amp;nbsp; action, not field selection. Variable vSet can if fact contain some kind of syntax as well, as its value will not be directly visible to user. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is - when i enter vExpr into Variables Overview window, and create the input box with vSet, it works as needed, i can enter 1,2 or &lt;SPAN style="font-size: 13.3333330154419px;"&gt; '&amp;lt;=3'.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;But when i load the same expr from load script, it evaluates $(vSet) at load time and writes f.e value 1 into the expression.&lt;/P&gt;&lt;P&gt;so i get &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;sum({$&amp;lt;klient ={1}&amp;gt;} käive) as vExpr. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;I tried all possible combinations of syntax but it gets evaluated, and later changes in vSet value from UI do not change the expression and chart. Can someone point me to the right direction, plz!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 13.3333330154419px; line-height: 1.5em;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Aug 2015 05:35:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936775#M323378</guid>
      <dc:creator />
      <dc:date>2015-08-31T05:35:43Z</dc:date>
    </item>
    <item>
      <title>Re: variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936776#M323379</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;May be this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;set vSet=2; // or&amp;nbsp; 1, or '&amp;lt;=3';&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;set vExpr=sum({$&amp;lt;klient ={@(vSet)}&amp;gt;} käive);&lt;/STRONG&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;STRONG&gt;set vExpr2 = Replace($(vExpr), '@', Chr(36));&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Aug 2015 08:18:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936776#M323379</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-08-31T08:18:14Z</dc:date>
    </item>
    <item>
      <title>Re: variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936777#M323380</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;i got it work like this:&lt;/P&gt;&lt;P&gt;set vSet=1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;set vExpr1 = "sum({$&amp;lt;klient={@(vSet)}&amp;gt;} käive)";&lt;/P&gt;&lt;P&gt;let vExpr = replace(vExpr1,'@',Chr(36));&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but it takes 2 lines in script and 2 variables where i have 20+ expressions and growing, sharing the vSet but different expressions. Perhaps it is possible to reduce it to 1 variable?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Aug 2015 08:41:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936777#M323380</guid>
      <dc:creator />
      <dc:date>2015-08-31T08:41:05Z</dc:date>
    </item>
    <item>
      <title>Re: variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936778#M323381</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Just a thought, but what if you try this?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Let vExpr1 = Replace('S&lt;/STRONG&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;STRONG&gt;um({$&amp;lt;klient={@(vSet)}&amp;gt;} käive)', '@', Chr(36));&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Aug 2015 08:44:02 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936778#M323381</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-08-31T08:44:02Z</dc:date>
    </item>
    <item>
      <title>Re: variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936779#M323382</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yep. Than you.&lt;/P&gt;&lt;P&gt;I spent 2 days on this.&lt;/P&gt;&lt;P&gt;Perhaps someone knows the shorter way?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Aug 2015 08:50:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936779#M323382</guid>
      <dc:creator />
      <dc:date>2015-08-31T08:50:34Z</dc:date>
    </item>
    <item>
      <title>Re: variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936780#M323383</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hahahaha no problem &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am glad I was able to help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best,&lt;/P&gt;&lt;P&gt;Sunny&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 31 Aug 2015 08:52:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/936780#M323383</guid>
      <dc:creator>sunny_talwar</dc:creator>
      <dc:date>2015-08-31T08:52:53Z</dc:date>
    </item>
    <item>
      <title>Re: variables within variables in load script</title>
      <link>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/1765628#M454249</link>
      <description>&lt;P&gt;i solved with:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Let vExpr1 = 'S&lt;/STRONG&gt;&lt;SPAN&gt;&lt;STRONG&gt;um({$&amp;lt;klient={'&amp;amp;Chr(36)&amp;amp;'(vSet)}&amp;gt;} käive)';&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Dec 2020 09:44:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/variables-within-variables-in-load-script/m-p/1765628#M454249</guid>
      <dc:creator>zanoni_fercam</dc:creator>
      <dc:date>2020-12-02T09:44:26Z</dc:date>
    </item>
  </channel>
</rss>

