<?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: Line Script Error with Variables in File Functions in Water Cooler</title>
    <link>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712705#M3326</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Bill, that’s what I was missing!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 04 Sep 2014 16:46:43 GMT</pubDate>
    <dc:creator>johncahillhp</dc:creator>
    <dc:date>2014-09-04T16:46:43Z</dc:date>
    <item>
      <title>Line Script Error with Variables in File Functions</title>
      <link>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712703#M3324</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am seeing an issue with my script intended to identify file existence. I picked up some code outlined in this post: &lt;A _jive_internal="true" href="https://community.qlik.com/thread/85612"&gt;http://community.qlik.com/thread/85612&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My code is fairly straight forward. Both of the &lt;SPAN style="color: #ff0000;"&gt;attempts&lt;/SPAN&gt; to set the variable provide the same error "Script line error".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM style=": ; color: #808080; font-size: 8pt;"&gt;QVD_PATH&lt;/EM&gt;&lt;/STRONG&gt;&lt;SPAN style="font-size: 8pt;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;"../../../QVD/WW/ICM/"&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #808080;"&gt;&lt;EM&gt;&lt;STRONG style="font-size: 8pt;"&gt;Let fQVD_AAEData= fldQVD &amp;amp; 'AAEData.qvd'; &lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #808080;"&gt;&lt;EM&gt;&lt;STRONG style=": ; color: #ff0000; font-size: 8pt;"&gt;Let vqvdexists = if(FileSize($(fQVD_ICMLog))&amp;gt;0,-1,0);&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;EM&gt;&lt;STRONG style="font-size: 8pt;"&gt;If FileSize($(fQVD_ICMLog))&amp;gt;0 Then&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;EM&gt;&lt;STRONG style="font-size: 8pt;"&gt; Let vqvdexists = -1;&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;EM&gt;&lt;STRONG style="font-size: 8pt;"&gt;Else &lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;EM&gt;&lt;STRONG style="font-size: 8pt;"&gt; Let vqvdexists = 0;&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="color: #808080;"&gt;&lt;EM&gt;&lt;STRONG style=": ; color: #ff0000; font-size: 8pt;"&gt;End If&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 10pt;"&gt;However when I use the resolved value instead of the variable it works.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #808080; font-size: 8pt;"&gt;&lt;EM&gt;&lt;STRONG style="font-size: 8pt;"&gt;Let vqvdexists = if(FileSize('../../../QVD/WW/ICM/AAEData.qvd')&amp;gt;0,-1,0);&lt;/STRONG&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 10pt;"&gt;I have tried other File functions such as QVDCreatetime with the same result.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 10pt;"&gt;What am I missing?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;John&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Sep 2014 16:02:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712703#M3324</guid>
      <dc:creator>johncahillhp</dc:creator>
      <dc:date>2014-09-04T16:02:10Z</dc:date>
    </item>
    <item>
      <title>Re: Line Script Error with Variables in File Functions</title>
      <link>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712704#M3325</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try adding single quotes around your dollar expansion, as in :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;EM style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #808080;"&gt;&lt;STRONG style="font-style: inherit; font-size: 8pt; font-family: inherit; color: #ff0000;"&gt;Let vqvdexists = if(FileSize(&lt;SPAN style="color: #008000;"&gt;'$(fQVD_ICMLog)'&lt;/SPAN&gt;)&amp;gt;0,-1,0);&lt;/STRONG&gt;&lt;/EM&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Sep 2014 16:08:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712704#M3325</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-09-04T16:08:54Z</dc:date>
    </item>
    <item>
      <title>Re: Line Script Error with Variables in File Functions</title>
      <link>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712705#M3326</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Bill, that’s what I was missing!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Sep 2014 16:46:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Water-Cooler/Line-Script-Error-with-Variables-in-File-Functions/m-p/712705#M3326</guid>
      <dc:creator>johncahillhp</dc:creator>
      <dc:date>2014-09-04T16:46:43Z</dc:date>
    </item>
  </channel>
</rss>

