<?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 Create file on error in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525814#M107106</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I would like to create an app which, upon encountering an error while in a reload task, would create a file with the text "error" in it.&lt;/P&gt;&lt;P&gt;So far, I know how to generate a .txt file with STORE into, but I can't find a way to generate the file for every possible error that might be encountered, and I also would like a file with only one line for "Error", instead of the multiple line :&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&amp;gt;&lt;BR /&gt;&amp;lt;QvdTableHeader&amp;gt;&lt;BR /&gt;&amp;lt;QvBuildNo&amp;gt;50689&amp;lt;/QvBuildNo&amp;gt;&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;For the error, I know there is ErrorMode, but I would like something that works for all possible errors, and within a reload task.&lt;/P&gt;&lt;P&gt;Is there a way to do it whith ErrorMode, or with something else ?&lt;/P&gt;&lt;P&gt;Best regards.&lt;/P&gt;</description>
    <pubDate>Thu, 31 Jul 2025 12:36:37 GMT</pubDate>
    <dc:creator>User93</dc:creator>
    <dc:date>2025-07-31T12:36:37Z</dc:date>
    <item>
      <title>Create file on error</title>
      <link>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525814#M107106</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;I would like to create an app which, upon encountering an error while in a reload task, would create a file with the text "error" in it.&lt;/P&gt;&lt;P&gt;So far, I know how to generate a .txt file with STORE into, but I can't find a way to generate the file for every possible error that might be encountered, and I also would like a file with only one line for "Error", instead of the multiple line :&lt;/P&gt;&lt;P&gt;&amp;lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&amp;gt;&lt;BR /&gt;&amp;lt;QvdTableHeader&amp;gt;&lt;BR /&gt;&amp;lt;QvBuildNo&amp;gt;50689&amp;lt;/QvBuildNo&amp;gt;&lt;/P&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;For the error, I know there is ErrorMode, but I would like something that works for all possible errors, and within a reload task.&lt;/P&gt;&lt;P&gt;Is there a way to do it whith ErrorMode, or with something else ?&lt;/P&gt;&lt;P&gt;Best regards.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Jul 2025 12:36:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525814#M107106</guid>
      <dc:creator>User93</dc:creator>
      <dc:date>2025-07-31T12:36:37Z</dc:date>
    </item>
    <item>
      <title>Re: Create file on error</title>
      <link>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525869#M107116</link>
      <description>&lt;P&gt;Maybe something like this added to your script and in sections to capture your error messages.&lt;/P&gt;&lt;P&gt;SET ErrorMode = 0;&lt;/P&gt;&lt;P&gt;LOAD * FROM [YourDataSource.qvd] (qvd);&lt;/P&gt;&lt;P&gt;// Capture error details if the previous load failed&lt;BR /&gt;SET vCustomErrMessage = '$(ScriptErrorDetails)';&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ErrorLog:&lt;BR /&gt;LOAD&lt;BR /&gt;Now() as ErrorTimestamp,&lt;BR /&gt;'Section Name' as ScriptSection, // Replace with the actual section name&lt;BR /&gt;'$(vCustomErrMessage)' as ErrorMessage,&lt;BR /&gt;'$(ScriptErrorCount)' as ErrorCount;&lt;/P&gt;&lt;P&gt;Store&amp;nbsp;ErrorLog into&amp;nbsp;ErrorLog.csv (TXT);&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 31 Jul 2025 13:10:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525869#M107116</guid>
      <dc:creator>TheLazyDeveloper</dc:creator>
      <dc:date>2025-07-31T13:10:55Z</dc:date>
    </item>
    <item>
      <title>Re: Create file on error</title>
      <link>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525874#M107118</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/215898"&gt;@User93&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When you get this text&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;EM&gt;&amp;lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&amp;gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;EM&gt;&amp;lt;QvdTableHeader&amp;gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG&gt;&lt;EM&gt;&amp;lt;QvBuildNo&amp;gt;50689&amp;lt;/QvBuildNo&amp;gt;&lt;/EM&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It means that when you store your QVD you forget to put in the end of store&amp;nbsp; .qvd&lt;STRONG&gt;(qvd)&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Bye!&lt;/P&gt;</description>
      <pubDate>Thu, 31 Jul 2025 13:22:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525874#M107118</guid>
      <dc:creator>rafaelencinas</dc:creator>
      <dc:date>2025-07-31T13:22:10Z</dc:date>
    </item>
    <item>
      <title>Re: Create file on error</title>
      <link>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525895#M107123</link>
      <description>&lt;P&gt;Thanks !&lt;/P&gt;&lt;P&gt;It does solve the number of lines issue.&lt;/P&gt;</description>
      <pubDate>Thu, 31 Jul 2025 14:43:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525895#M107123</guid>
      <dc:creator>User93</dc:creator>
      <dc:date>2025-07-31T14:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: Create file on error</title>
      <link>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525896#M107124</link>
      <description>&lt;P&gt;Thank you !&lt;/P&gt;&lt;P&gt;After a few tests, I ended with this :&lt;/P&gt;&lt;P&gt;SET ErrorMode = 0;&lt;/P&gt;&lt;P&gt;Load query&lt;/P&gt;&lt;P&gt;if ScriptErrorCount&amp;gt;0 then&lt;/P&gt;&lt;P&gt;File:&lt;/P&gt;&lt;P&gt;Load&lt;BR /&gt;'Error' AS [Error]&lt;/P&gt;&lt;P&gt;AutoGenerate 1&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;STORE File Into 'lib://Test/Test_Error.txt'(TXT);&lt;/P&gt;&lt;P&gt;Drop Table File;&lt;/P&gt;&lt;P&gt;end if&lt;/P&gt;&lt;P&gt;And it does work !&lt;/P&gt;</description>
      <pubDate>Thu, 31 Jul 2025 14:45:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Create-file-on-error/m-p/2525896#M107124</guid>
      <dc:creator>User93</dc:creator>
      <dc:date>2025-07-31T14:45:29Z</dc:date>
    </item>
  </channel>
</rss>

