<?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 Re: Create a date range within a button in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680797#M1057803</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here's the simple way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="68516" alt="Button.jpg" class="jive-image" height="212" src="https://community.qlik.com/legacyfs/online/68516_Button.jpg" style="width: 433px; height: 211.611px;" width="433" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 08 Oct 2014 12:46:48 GMT</pubDate>
    <dc:creator>ljackson</dc:creator>
    <dc:date>2014-10-08T12:46:48Z</dc:date>
    <item>
      <title>Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680791#M1057797</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I need to select a date range (on a button) that does not include the current week.&amp;nbsp;&amp;nbsp; I've searched the archives and found SO many date range related questions, but nothing that answers my query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I want to select the last 4 weeks, previous to the current week.&amp;nbsp; This week is week 41, so I need the button to select weeks 37 to 40. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've set the button actions as below, and it very happily selects from week 37 onwards, but I can't work out how to exclude the current week [max(WeekNo()].&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anyone help?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Date Range.jpg" class="jive-image" src="/legacyfs/online/68495_Date Range.jpg" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 11:00:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680791#M1057797</guid>
      <dc:creator>ljackson</dc:creator>
      <dc:date>2014-10-08T11:00:38Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680792#M1057798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=('&amp;gt;=' &amp;amp; Week(today()-35) &amp;amp; ' and ' &amp;amp; '&amp;lt; ' &amp;amp; Week(today()-7) &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 11:05:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680792#M1057798</guid>
      <dc:creator>DavidFoster1</dc:creator>
      <dc:date>2014-10-08T11:05:25Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680793#M1057799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you David.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tweaked your expression to this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=('&amp;gt;=' &amp;amp; Week(today()-28) &amp;amp; ' and ' &amp;amp; '&amp;lt;' &amp;amp; Week(today()))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the selection box it now shows this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Selection Box.jpg" class="jive-image" src="/legacyfs/online/68497_Selection Box.jpg" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;but ........it's selecting all weeks less than 41, so has selected weeks 1 to 40.&amp;nbsp;&amp;nbsp; It seems the second part of the expression is over-riding the first part.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 11:25:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680793#M1057799</guid>
      <dc:creator>ljackson</dc:creator>
      <dc:date>2014-10-08T11:25:27Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680794#M1057800</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I switched it around to this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=('&amp;lt;' &amp;amp; Week(today()) &amp;amp; ' and ' &amp;amp; '&amp;gt;=' &amp;amp; Week(today()-28))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But now it's ignoring the first part of the expression, and includes weeks 37 to 52.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 11:34:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680794#M1057800</guid>
      <dc:creator>ljackson</dc:creator>
      <dc:date>2014-10-08T11:34:22Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680795#M1057801</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Could you share your sample app that shows the issue?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 11:50:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680795#M1057801</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2014-10-08T11:50:48Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680796#M1057802</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I worked it out - thank you David for helping me find the last piece in the puzzle&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I set up a variable, then selected the variable for the Field.&amp;nbsp;&amp;nbsp; This then selected weeks 37 to 40.&amp;nbsp;&amp;nbsp; I think this is the long winded way of doing it, but I get the result I need so I'm happy!&amp;nbsp; &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;Thanks again&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Set Variable.jpg" class="jive-image" height="263" src="/legacyfs/online/68506_Set Variable.jpg" style="width: 433px; height: 262.594px;" width="433" /&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Select Variable.jpg" class="jive-image" height="228" src="/legacyfs/online/68515_Select Variable.jpg" style="width: 436px; height: 227.875px;" width="436" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 12:42:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680796#M1057802</guid>
      <dc:creator>ljackson</dc:creator>
      <dc:date>2014-10-08T12:42:42Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680797#M1057803</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here's the simple way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG __jive_id="68516" alt="Button.jpg" class="jive-image" height="212" src="https://community.qlik.com/legacyfs/online/68516_Button.jpg" style="width: 433px; height: 211.611px;" width="433" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 12:46:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680797#M1057803</guid>
      <dc:creator>ljackson</dc:creator>
      <dc:date>2014-10-08T12:46:48Z</dc:date>
    </item>
    <item>
      <title>Re: Create a date range within a button</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680798#M1057804</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You are welcome. Could I be cheeky and get you mark my response as the correct/helpful answer. I know! I am a total points junkie &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 08 Oct 2014 12:51:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-date-range-within-a-button/m-p/680798#M1057804</guid>
      <dc:creator>DavidFoster1</dc:creator>
      <dc:date>2014-10-08T12:51:59Z</dc:date>
    </item>
  </channel>
</rss>

