<?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 Dynamically change URL of a button in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230992#M82771</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You sure this doesn't work on the server?&lt;/P&gt;&lt;P&gt;Can you try putting just someple line in sub and test it out another option, which works in "web" environment usually. Just call:&lt;/P&gt;&lt;P&gt;window.open &lt;A href="http://www.google.com"&gt;http://www.google.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Sorry, don;t have access to a server right now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Feb 2010 02:31:32 GMT</pubDate>
    <dc:creator>disqr_rm</dc:creator>
    <dc:date>2010-02-04T02:31:32Z</dc:date>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230989#M82768</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In QlikView 9, I need to write a macro which take an existing button within a document and change the URL which the button launches based on selections within the sheet. I know how to find the selections and build the URL, but what I cannot determine is what properties to set on the button.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE ___default_attr="plain" class="jive_text_macro jive_macro_code" jivemacro="code"&gt;&lt;BR /&gt;set btn = ActiveDoc.GetSheetObject("BU23")&lt;BR /&gt;set prop = btn.GetProperties&lt;BR /&gt;--- In here, I need to set the properties for the URL to launch when the button is clicked&lt;BR /&gt;btn.SetProperties prop&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;I've checked through the forums and have not found an example of this, and the API reference refers to a type if IArrayOfActionItems but that type is not defined in the API qvw.&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 00:15:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230989#M82768</guid>
      <dc:creator />
      <dc:date>2010-02-04T00:15:52Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230990#M82769</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You are correct, that definition is missing in the API Guide.&lt;/P&gt;&lt;P&gt;A workaround I can suggest. Have your button call a sub where you can open IE with the manipulated URL. Something like this should work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;BR /&gt;strLink= "&lt;A href="http://www.yahoo.com"&gt;http://www.yahoo.com&lt;/A&gt;"&lt;BR /&gt;Set objIExplorer = CreateObject("internetexplorer.application")&lt;BR /&gt;objIExplorer.visible = True&lt;BR /&gt;objIExplorer.navigate strLink&lt;BR /&gt;Set objIExplorer = Nothing&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 01:58:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230990#M82769</guid>
      <dc:creator>disqr_rm</dc:creator>
      <dc:date>2010-02-04T01:58:49Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230991#M82770</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I should add that I need this to work when used from the QlikView server. Launching an application won't work, as it runs on the server.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 02:19:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230991#M82770</guid>
      <dc:creator />
      <dc:date>2010-02-04T02:19:37Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230992#M82771</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You sure this doesn't work on the server?&lt;/P&gt;&lt;P&gt;Can you try putting just someple line in sub and test it out another option, which works in "web" environment usually. Just call:&lt;/P&gt;&lt;P&gt;window.open &lt;A href="http://www.google.com"&gt;http://www.google.com&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Sorry, don;t have access to a server right now.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 02:31:32 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230992#M82771</guid>
      <dc:creator>disqr_rm</dc:creator>
      <dc:date>2010-02-04T02:31:32Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230993#M82772</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Instead of messing with properties, define the button launch action as a variable and then manipulate the variable contents.&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 04:32:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230993#M82772</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2010-02-04T04:32:21Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230994#M82773</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="jive_text_macro jive_macro_quote" jivemacro="quote"&gt;&lt;BR /&gt;Rob Wunderlich wrote:&lt;BR /&gt;Instead of messing with properties, define the button launch action as a variable and then manipulate the variable contents.&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;That's actually the first thing I thought of, but it doesn't seem to work. It's possible I'm doing something wrong.&lt;/P&gt;&lt;P&gt;Can you provide an example of setting the target of a launch action as a variable? I've gotten the variable set via the macro, but I cannot get the button to then launch the location specified by the variable.&lt;/P&gt;&lt;P&gt;-Kevin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 14:43:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230994#M82773</guid>
      <dc:creator />
      <dc:date>2010-02-04T14:43:18Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230995#M82774</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="jive_text_macro jive_macro_quote" jivemacro="quote"&gt;&lt;BR /&gt;Rakesh wrote:&lt;BR /&gt;You sure this doesn't work on the server?&lt;BR /&gt;Can you try putting just someple line in sub and test it out another option, which works in "web" environment usually. Just call:&lt;BR /&gt;window.open &lt;A href="http://www.google.com"&gt;http://www.google.com&lt;/A&gt;&lt;BR /&gt;Sorry, don;t have access to a server right now. &amp;lt;div&amp;gt;&amp;lt;/div&amp;gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;I believe window.open is for VB, not VB Script, but I will confirm that. I did this approach, which did &lt;I&gt;not&lt;/I&gt; work on the server:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;set app = ActiveDocument.Getapplication&lt;BR /&gt; app.Launch baseURL &amp;amp; "?" &amp;amp; params, ""&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;-Kevin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 15:27:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230995#M82774</guid>
      <dc:creator />
      <dc:date>2010-02-04T15:27:09Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230996#M82775</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="jive_text_macro jive_macro_quote" jivemacro="quote"&gt;&lt;BR /&gt;troj wrote:Can you provide an example of setting the target of a launch action as a variable? I've gotten the variable set via the macro, but I cannot get the button&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Kevin,&lt;/P&gt;&lt;P&gt;Attached is an example of deriving the launch URL from selections without using a macro. Two methods are shown, build the URL in an Expression and building in a Variable. Hope this is what you were looking for.&lt;/P&gt;&lt;P&gt;-Rob&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 15:50:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230996#M82775</guid>
      <dc:creator>rwunderlich</dc:creator>
      <dc:date>2010-02-04T15:50:35Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230997#M82776</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've continued to play with this, in hopes of finding a solution. One thing of note is that I was originally trying this via the Ajax Client, which is something I'd still like to get working.&lt;/P&gt;&lt;P&gt;When I switch to the IE Plugin, I can use the following VB Script within a macro, and have it work. More than likely, this is because with IE, VB Script can run within the browser.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;if (params = "") then&lt;BR /&gt; msgbox "No selections"&lt;BR /&gt; else&lt;BR /&gt; dim app&lt;BR /&gt; set app = ActiveDocument.Getapplication&lt;BR /&gt; app.Launch baseURL &amp;amp; "?" &amp;amp; params, ""&lt;BR /&gt; end if&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;I'd still like a method which works via Ajax, where the macro directly launches the page, or where I can change the launch URL for a button via a macro, or change a variable and have the button launch the contents of the variable.&lt;/P&gt;&lt;P&gt;-Kevin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 15:58:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230997#M82776</guid>
      <dc:creator />
      <dc:date>2010-02-04T15:58:39Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230998#M82777</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="jive_text_macro jive_macro_quote" jivemacro="quote"&gt;&lt;BR /&gt;Rob Wunderlich wrote:&lt;BR /&gt;Attached is an example of deriving the launch URL from selections without using a macro. Two methods are shown, build the URL in an Expression and building in a Variable. Hope this is what you were looking for. &amp;lt;div&amp;gt;&amp;lt;/div&amp;gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Thanks, Rob -- that showed me where I went wrong! I was trying&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;=$(variable)&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;instead of&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;=variable&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;as the URL.&lt;/P&gt;&lt;P&gt;It's the little things....&lt;/P&gt;&lt;P&gt;I'll give that a shot with the Ajax client, and see if it works.&lt;/P&gt;&lt;P&gt;-Kevin&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 16:01:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230998#M82777</guid>
      <dc:creator />
      <dc:date>2010-02-04T16:01:52Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230999#M82778</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Interesting - I'm finding behavioral differences between the IE Plugin and the Ajax client. What works in one doesn't seem to want to work in the other.&lt;/P&gt;&lt;P&gt;In the IE plugin, I can have the macro determine the URL and launch it via this code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;if (params = "") then&amp;lt;pre&amp;gt; msgbox "No selections"&lt;BR /&gt; else&lt;BR /&gt; dim app&lt;BR /&gt; set app = ActiveDocument.Getapplication&lt;BR /&gt; app.Launch baseURL &amp;amp; "?" &amp;amp; params, ""&lt;BR /&gt; end if&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;However that does not work in the Ajax client. For the Ajax client, I have to set the value into a variable, and have the button have a second action of "Open URL" with a target of&lt;BR /&gt;&lt;BR /&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;=URLvariable&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;. &lt;BR /&gt;&lt;BR /&gt;Where it gets interesting is the method that works for the Ajax client doesn't work in the IE plugin, and vice-versa!&lt;BR /&gt;&lt;BR /&gt;So, the client to be used affects the required solution. &lt;BR /&gt;&lt;BR /&gt;-Kevin&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 16:16:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/230999#M82778</guid>
      <dc:creator />
      <dc:date>2010-02-04T16:16:31Z</dc:date>
    </item>
    <item>
      <title>Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/231000#M82779</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That's what I thought, and so asked you that you are sure if it doesn't work on the server. Regarding AJAX, I don't know much.&lt;/P&gt;&lt;P&gt;Glad that you see something positive.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Feb 2010 16:28:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/231000#M82779</guid>
      <dc:creator>disqr_rm</dc:creator>
      <dc:date>2010-02-04T16:28:30Z</dc:date>
    </item>
    <item>
      <title>Re: Dynamically change URL of a button</title>
      <link>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/231001#M82780</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Troj, Did you find a macro that works fine via Ajax?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 Oct 2013 11:22:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Dynamically-change-URL-of-a-button/m-p/231001#M82780</guid>
      <dc:creator />
      <dc:date>2013-10-30T11:22:34Z</dc:date>
    </item>
  </channel>
</rss>

