<?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 Excel file information in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305666#M1200977</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Well, I don't want to load the file...i just want to load information about the file.&lt;BR /&gt;Like, filesize, filetime, filename...etc. My code work fine for a text file but not an Excel file.&lt;BR /&gt;I don't know why.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 12 Feb 2011 20:34:57 GMT</pubDate>
    <dc:creator>qw_johan</dc:creator>
    <dc:date>2011-02-12T20:34:57Z</dc:date>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305664#M1200975</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;I am trying to read file information from an Excel file. But I get nothing, no information.&lt;BR /&gt;It works fine with textfiles. Do I need to change something to read Excel file information?&lt;BR /&gt;Information is then displayed in a text object.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE ___default_attr="plain" class="jive_text_macro jive_macro_code" jivemacro="code"&gt;Let vFile= 'MyExcelFile.xls';&lt;BR /&gt;[Fileinformation]:&lt;BR /&gt;LOAD&lt;BR /&gt;'$(vFile)' as vFile_Name,&lt;BR /&gt;FileName('$(vFile)') as FileName,&lt;BR /&gt;FileSize('$(vFile)') as FileSize,&lt;BR /&gt;FileTime( '$(vFile)') as FileTime&lt;BR /&gt;From '$(vFile)';&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 12 Feb 2011 11:54:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305664#M1200975</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-02-12T11:54:11Z</dc:date>
    </item>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305665#M1200976</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You need to specify the sheetname.&lt;/P&gt;&lt;P&gt;Try to use the assistant and see, how the script looks:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;LOAD .... FROM [MyPath\MyExcelFile.xls] (biff, no labels, table is MySheet$);&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;HTH&lt;BR /&gt;Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 12 Feb 2011 18:16:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305665#M1200976</guid>
      <dc:creator>prieper</dc:creator>
      <dc:date>2011-02-12T18:16:59Z</dc:date>
    </item>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305666#M1200977</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Well, I don't want to load the file...i just want to load information about the file.&lt;BR /&gt;Like, filesize, filetime, filename...etc. My code work fine for a text file but not an Excel file.&lt;BR /&gt;I don't know why.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 12 Feb 2011 20:34:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305666#M1200977</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-02-12T20:34:57Z</dc:date>
    </item>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305667#M1200978</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you use the From you sometimes have to tell QV explicitly what the file format is. In this case it is necessary to add the work (biff) at the end of the file name. For example,&lt;/P&gt;&lt;P&gt;MyExcelFile.xls (biff)&lt;/P&gt;&lt;P&gt;If you just want file information you can also use the filelist() function as shown below from the QlikView Explorer v8.01 application:&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;Sub DoDir(Root)&lt;BR /&gt; For each Ext in '$(v_Extension)'&lt;BR /&gt;&lt;BR /&gt; For each File in Filelist (Root&amp;amp;'\*.'&amp;amp;Ext)&lt;BR /&gt;&lt;BR /&gt; let FileExtension = lower(mid(File,Index(File,'.',-1)+1));&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt; Main:&lt;BR /&gt; Load&lt;BR /&gt; Name,&lt;BR /&gt; Right(Name,Len(Name)-Index(Name,'\',-1)) AS File,&lt;BR /&gt; Left(Name,Index(Name,'\',-1)) AS FilePath,&lt;BR /&gt; subfield(mid(Name,Index(Name,'\',-2)+1),'\',1) AS FileFolder,&lt;BR /&gt; FileSize(Name) as Size,&lt;BR /&gt; FileTime(Name) as FileTime,&lt;BR /&gt; date(subfield(FileTime(Name),' ',1),'M/D/YY') as FileDate,&lt;BR /&gt; if(Index(Name,'.', -1)&amp;gt;=NumSum(Len(Name),-6) and Index(Name,'.', -1)&amp;gt;0, lower(right(Name, Len(Name)- Index(Name,'.', -1))), '') as Extension,&lt;BR /&gt; date(monthstart(FileTime(Name)),'MMM-YY') as FileMonthYear,&lt;BR /&gt; year(FileTime(Name)) as FileYear;&lt;BR /&gt; Load * Inline "&lt;BR /&gt; Name&lt;BR /&gt; $(File)";&lt;BR /&gt; // ************* Load QVD Structure if requested:&lt;BR /&gt; if FileExtension = 'qvd' and v_AnalyzeQVD = 'Yes' then&lt;BR /&gt;&lt;BR /&gt; call LoadQVDStructure(File)&lt;BR /&gt;&lt;BR /&gt; end if&lt;BR /&gt;&lt;BR /&gt; Next File&lt;BR /&gt;&lt;BR /&gt; Next Ext&lt;BR /&gt;&lt;BR /&gt; For each Dir in Dirlist(Root&amp;amp;'\*')&lt;BR /&gt;&lt;BR /&gt; Call DoDir(Dir)&lt;BR /&gt; Next Dir&lt;BR /&gt;&lt;BR /&gt;End sub&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 12 Feb 2011 21:02:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305667#M1200978</guid>
      <dc:creator>pover</dc:creator>
      <dc:date>2011-02-12T21:02:46Z</dc:date>
    </item>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305668#M1200979</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Easier than that, just a few checks on your code will do:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;Let vFile= 'ExcelFile.xls'; FileInformation: LOAD '$(vFile)' as vFile_Name, FileName('$(vFile)') as FileName, // not needed since you already have the file name in the variable FileSize('$(vFile)') as FileSize, FileTime('$(vFile)') as FileTimeAUTOGENERATE 1; // another way to create a table&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Hope that helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 13 Feb 2011 01:54:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305668#M1200979</guid>
      <dc:creator>Miguel_Angel_Baeyens</dc:creator>
      <dc:date>2011-02-13T01:54:25Z</dc:date>
    </item>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305669#M1200980</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Miguel, Karl and Peter for your help!&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Big Smile" src="http://community.qlik.com/emoticons/emotion-2.gif" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 13 Feb 2011 10:18:46 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305669#M1200980</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-02-13T10:18:46Z</dc:date>
    </item>
    <item>
      <title>Excel file information</title>
      <link>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305670#M1200981</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try This&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for each File in filelist ('$(QVDFolder)\*.qvd')&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;'$(File)' as F33,&lt;/P&gt;&lt;P&gt;left(subField('$(File)', '\', subStringCount('$(File)','\')+1), len(subField('$(File)', '\', subStringCount('$(File)','\')+1))-4) as F3,&lt;/P&gt;&lt;P&gt;FileSize( '$(File)' ) as Size,&lt;/P&gt;&lt;P&gt;FileTime( '$(File)' ) as FileTime autogenerate 1;&lt;/P&gt;&lt;P&gt;next File&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Himanshu Sethi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 13 Feb 2011 11:56:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Excel-file-information/m-p/305670#M1200981</guid>
      <dc:creator />
      <dc:date>2011-02-13T11:56:58Z</dc:date>
    </item>
  </channel>
</rss>

