<?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 Condition Proble. in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146230#M24826</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish&lt;/P&gt;&lt;P&gt;Manish the solution you gave worked,Thank you sooo much&lt;/P&gt;&lt;P&gt;Regrds&lt;/P&gt;&lt;P&gt;Sikandar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 09 Jun 2009 18:17:25 GMT</pubDate>
    <dc:creator />
    <dc:date>2009-06-09T18:17:25Z</dc:date>
    <item>
      <title>Condition Proble.</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146228#M24824</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="background: #cedefd;"&gt;Hi&lt;/P&gt;&lt;P style="background: #cedefd;"&gt;I m having a problem in writing a macro here.I have two variables name My Budget and Total Sale.In Mybudget i have assign it a value 8000.and in totalSale the value is 69950(sum of some expression).then i use a two msg box to show each value .it is showing the right value.then i use a conditon that if the value of total sale which is 69950 is less than 8000 then show a msg box which says my sales are less else msg box show that my Sales are greater.The right answere is that it has to show my sales are greater but it is showing My sales are lesss.i dont know y ....here is my Script&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;Sub ShowPoPUp&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;set a=ActiveDocument.Variables("MyBudget")&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;set v=ActiveDocument.Variables("TotalSale")&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;Msgbox(a.getcontent.string)&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;Msgbox(v.getcontent.string)&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;if ((v.getcontent.string) &amp;lt; (a.getcontent.string)) then&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;MsgBox ("MySales are less than 8000")&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;else&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;MsgBox ("MySales are greater than 8000")&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;end if&lt;/P&gt;&lt;P style="margin: 0in 0in 0pt; mso-layout-grid-align: none;"&gt;end Sub&lt;/P&gt;&lt;P style="background: #cedefd;"&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2009 12:42:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146228#M24824</guid>
      <dc:creator />
      <dc:date>2009-06-09T12:42:29Z</dc:date>
    </item>
    <item>
      <title>Condition Proble.</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146229#M24825</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Sikandar,&lt;/P&gt;&lt;P&gt;Actually the problem is in Comparing the Values. You are comparing two string values, which is actually a numeric. I have modified the function.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Sub ShowPoPUp&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;Dim a,v&lt;BR /&gt;set a=ActiveDocument.Variables("MyBudget")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;set v=ActiveDocument.Variables("TotalSale")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Msgbox(a.getcontent.string)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Msgbox(v.getcontent.string)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;if (CLng(v.getcontent.string) &amp;lt; CLng(a.getcontent.string)) then&lt;BR /&gt; MsgBox ("MySales are less than 8000")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;else&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MsgBox ("MySales are greater than 8000")&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;end if&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;end Sub&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Hope it will work.&lt;/P&gt;&lt;P&gt;- Manish&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2009 17:33:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146229#M24825</guid>
      <dc:creator>manishkumar75</dc:creator>
      <dc:date>2009-06-09T17:33:58Z</dc:date>
    </item>
    <item>
      <title>Condition Proble.</title>
      <link>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146230#M24826</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish&lt;/P&gt;&lt;P&gt;Manish the solution you gave worked,Thank you sooo much&lt;/P&gt;&lt;P&gt;Regrds&lt;/P&gt;&lt;P&gt;Sikandar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Jun 2009 18:17:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Condition-Proble/m-p/146230#M24826</guid>
      <dc:creator />
      <dc:date>2009-06-09T18:17:25Z</dc:date>
    </item>
  </channel>
</rss>

