<?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 Type mismatch error in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211534#M65774</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what's wrong in that code...&lt;/P&gt;&lt;P&gt;it shows type mismatch error....&lt;/P&gt;&lt;P&gt;in&lt;/P&gt;&lt;P&gt;Type mismatch: 'deleteReport'&lt;/P&gt;&lt;P&gt;Type mismatch: 'printReportPDF'&lt;/P&gt;&lt;P&gt;Type mismatch: 'redimarrReports'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;code is..&lt;/P&gt;&lt;P&gt;sub sendReport&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;tempFolder = "c:"&lt;/P&gt;&lt;P&gt;Set oReports = ActiveDocument.Fields("reportID").GetPossibleValues&lt;/P&gt;&lt;P&gt;Dim arrReports()&lt;/P&gt;&lt;P&gt;if oReports.Count &amp;gt; 0 then&lt;/P&gt;&lt;P&gt;redimarrReports(oReports.Count)&lt;/P&gt;&lt;P&gt;for i = 0 to oReports.Count -1&lt;/P&gt;&lt;P&gt;reportID = oReports.Item(i).Text&lt;/P&gt;&lt;P&gt;set rep = ActiveDocument.GetReport(reportID)&lt;/P&gt;&lt;P&gt;reportName = rep.Name&lt;/P&gt;&lt;P&gt;reportFile = tempFolder&amp;amp;reportID&amp;amp; "_" &amp;amp;reportName&amp;amp; ".pdf"&lt;/P&gt;&lt;P&gt;'deleteReport (reportFile) 'Cleaning out any previous report&lt;/P&gt;&lt;P&gt;'arrReports(i) = reportFile&lt;/P&gt;&lt;P&gt;'Print report to PDF&lt;/P&gt;&lt;P&gt;msgbox(reportFile)&lt;/P&gt;&lt;P&gt;printReportPDF reportID, reportFile&lt;/P&gt;&lt;P&gt;' Check the file is printed, before trying to send it&lt;/P&gt;&lt;P&gt;checkOutputFile(reportFile)&lt;/P&gt;&lt;P&gt;next&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;end if&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;end sub&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 13 Apr 2010 06:47:49 GMT</pubDate>
    <dc:creator />
    <dc:date>2010-04-13T06:47:49Z</dc:date>
    <item>
      <title>Type mismatch error</title>
      <link>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211534#M65774</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what's wrong in that code...&lt;/P&gt;&lt;P&gt;it shows type mismatch error....&lt;/P&gt;&lt;P&gt;in&lt;/P&gt;&lt;P&gt;Type mismatch: 'deleteReport'&lt;/P&gt;&lt;P&gt;Type mismatch: 'printReportPDF'&lt;/P&gt;&lt;P&gt;Type mismatch: 'redimarrReports'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;code is..&lt;/P&gt;&lt;P&gt;sub sendReport&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;tempFolder = "c:"&lt;/P&gt;&lt;P&gt;Set oReports = ActiveDocument.Fields("reportID").GetPossibleValues&lt;/P&gt;&lt;P&gt;Dim arrReports()&lt;/P&gt;&lt;P&gt;if oReports.Count &amp;gt; 0 then&lt;/P&gt;&lt;P&gt;redimarrReports(oReports.Count)&lt;/P&gt;&lt;P&gt;for i = 0 to oReports.Count -1&lt;/P&gt;&lt;P&gt;reportID = oReports.Item(i).Text&lt;/P&gt;&lt;P&gt;set rep = ActiveDocument.GetReport(reportID)&lt;/P&gt;&lt;P&gt;reportName = rep.Name&lt;/P&gt;&lt;P&gt;reportFile = tempFolder&amp;amp;reportID&amp;amp; "_" &amp;amp;reportName&amp;amp; ".pdf"&lt;/P&gt;&lt;P&gt;'deleteReport (reportFile) 'Cleaning out any previous report&lt;/P&gt;&lt;P&gt;'arrReports(i) = reportFile&lt;/P&gt;&lt;P&gt;'Print report to PDF&lt;/P&gt;&lt;P&gt;msgbox(reportFile)&lt;/P&gt;&lt;P&gt;printReportPDF reportID, reportFile&lt;/P&gt;&lt;P&gt;' Check the file is printed, before trying to send it&lt;/P&gt;&lt;P&gt;checkOutputFile(reportFile)&lt;/P&gt;&lt;P&gt;next&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;end if&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;end sub&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Apr 2010 06:47:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211534#M65774</guid>
      <dc:creator />
      <dc:date>2010-04-13T06:47:49Z</dc:date>
    </item>
    <item>
      <title>Type mismatch error</title>
      <link>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211535#M65775</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can you attach some application so that we can Test it&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Apr 2010 07:51:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211535#M65775</guid>
      <dc:creator>deepakk</dc:creator>
      <dc:date>2010-04-13T07:51:07Z</dc:date>
    </item>
    <item>
      <title>Type mismatch error</title>
      <link>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211536#M65776</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;One possibility is that the variable reportName (that holds the Report Name) has spaces (or logically, a comma). Try replacing spaces with an underscore.&lt;/P&gt;&lt;P&gt;Ex:&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;reportName = rep.Name&lt;BR /&gt;TO&lt;BR /&gt;reportName = Replace(rep.Name," ","_")&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;I believe you have the Sub routenes printReportPDF and checkOutputFile defined in the macro. If they are not existing you would get a similiar error.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 13 Apr 2010 08:10:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Type-mismatch-error/m-p/211536#M65776</guid>
      <dc:creator>vupen</dc:creator>
      <dc:date>2010-04-13T08:10:57Z</dc:date>
    </item>
  </channel>
</rss>

