<?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: write 2D data array to spreadsheet with good alignment in LabVIEW</title>
    <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058642#M871908</link>
    <description>&lt;P&gt;The default field delimiter is a tab. The data values in the second and third columns appear to have more characters than the default spacing of a tab. This results in the&amp;nbsp;tabs between those columns occuring farther to the right than in the header. I suspect that if you read the file as text and display it with '\' Codes display mode on a string indicator, you will find the same number of tabs (delimiters) in the header row as in the data rows. &amp;nbsp;The data has 12 or 13 characters as formatted (or fewer where trailing zeros are suppressed).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Format the data as fixed field widths. You cannot do this with Write to Spreadsheet File.vi. You will need to use string functions to perform&amp;nbsp;the conversions and formatting and then use&amp;nbsp;Write to Text File.vi.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or change the tab spacing in the program you are using to display the results. &amp;nbsp;If the tabs were about 15-18 spaces apart, you wuold not see the problem.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Lynn&lt;/P&gt;</description>
    <pubDate>Sat, 29 Nov 2014 16:34:49 GMT</pubDate>
    <dc:creator>johnsold</dc:creator>
    <dc:date>2014-11-29T16:34:49Z</dc:date>
    <item>
      <title>write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058640#M871906</link>
      <description>&lt;P&gt;Using "write to spreadsheet file"&amp;nbsp;function to write 2D array, &amp;nbsp; I always have the problem that headers cannot align well wiith the data. See attached snapshot please (There are 7 column headers.)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;IMG src="https://ip1.i.lithium.com/d2006cbe2547b7fcabd1f57d671639f5034cf814/68747470733a2f2f6e692e6c69746869756d2e636f6d2f74352f696d6167652f736572766572706167652f696d6167652d69642f31363030333069373633313438383846363233373442312f696d6167652d73697a652f6f726967696e616c3f763d6d70626c2d312670783d2d31" border="0" alt="data alignment with headers.PNG" title="data alignment with headers.PNG" align="center" /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;WT&lt;/P&gt;
&lt;P&gt;LV2013sp1&lt;/P&gt;</description>
      <pubDate>Sat, 29 Nov 2014 16:16:46 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058640#M871906</guid>
      <dc:creator>weitong</dc:creator>
      <dc:date>2014-11-29T16:16:46Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058642#M871908</link>
      <description>&lt;P&gt;The default field delimiter is a tab. The data values in the second and third columns appear to have more characters than the default spacing of a tab. This results in the&amp;nbsp;tabs between those columns occuring farther to the right than in the header. I suspect that if you read the file as text and display it with '\' Codes display mode on a string indicator, you will find the same number of tabs (delimiters) in the header row as in the data rows. &amp;nbsp;The data has 12 or 13 characters as formatted (or fewer where trailing zeros are suppressed).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Format the data as fixed field widths. You cannot do this with Write to Spreadsheet File.vi. You will need to use string functions to perform&amp;nbsp;the conversions and formatting and then use&amp;nbsp;Write to Text File.vi.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Or change the tab spacing in the program you are using to display the results. &amp;nbsp;If the tabs were about 15-18 spaces apart, you wuold not see the problem.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Lynn&lt;/P&gt;</description>
      <pubDate>Sat, 29 Nov 2014 16:34:49 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058642#M871908</guid>
      <dc:creator>johnsold</dc:creator>
      <dc:date>2014-11-29T16:34:49Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058645#M871909</link>
      <description>&lt;P&gt;Plain text display cannot handle tabs very well.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can take the spreadsheet file and open it in e.g. excel and it will all look great. Spreadsheet files have no formatting information, just row and column delimiters.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to create nicely formatted report files in LabVIEW, use the report generation tools and pick an output file format that is suitable for what you want to display (e.g. html).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If you want to display your data&amp;nbsp;in a plain text indicator, you would need to do two things:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;use a fixed-width font (e.g. courier)&lt;/LI&gt;
&lt;LI&gt;Format all fields with a fixed widh of padding characters.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;For a tabular front panel indicator, you should &lt;STRONG&gt;use a table&lt;/STRONG&gt;. You can write the header strings into the table header.&lt;/P&gt;</description>
      <pubDate>Sun, 30 Nov 2014 05:32:23 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058645#M871909</guid>
      <dc:creator>altenbach</dc:creator>
      <dc:date>2014-11-30T05:32:23Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058705#M871949</link>
      <description>&lt;P&gt;Thanks to both of you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;WT&lt;/P&gt;
&lt;P&gt;LV2013sp1&lt;/P&gt;</description>
      <pubDate>Sun, 30 Nov 2014 01:23:45 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3058705#M871949</guid>
      <dc:creator>weitong</dc:creator>
      <dc:date>2014-11-30T01:23:45Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3554993#M994658</link>
      <description>&lt;P&gt;Hello Lynn,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have met the same problem, do you know how to change the tab spacing?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regard&lt;/P&gt;</description>
      <pubDate>Wed, 07 Dec 2016 08:38:17 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3554993#M994658</guid>
      <dc:creator>TUDarmstadtLLX</dc:creator>
      <dc:date>2016-12-07T08:38:17Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3554997#M994661</link>
      <description>&lt;P&gt;Hi LLX,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;tab spacing is set in the text editor you use to view the text file!&lt;/P&gt;
&lt;P&gt;(Each text editor may use it's own definition for the equation 1 tab = x spaces, but I usually use tab = 8 spaces…)&lt;/P&gt;</description>
      <pubDate>Wed, 07 Dec 2016 08:44:19 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3554997#M994661</guid>
      <dc:creator>GerdW</dc:creator>
      <dc:date>2016-12-07T08:44:19Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3555192#M994715</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://ni.lithium.com/t5/user/viewprofilepage/user-id/347969"&gt;@TUDarmstadtLLX&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;Hello Lynn,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have met the same problem, do you know how to change the tab spacing?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Best Regard&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Don't start futzing with your text editor.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Use a spreadsheet program to view the files, like MS Office Excel ($$$) or Open Office Calc (free).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Spreadsheet programs will import a Tab or Comma deliminated text file and put all the data in nice neat columns for you.&lt;/P&gt;</description>
      <pubDate>Wed, 07 Dec 2016 15:42:15 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3555192#M994715</guid>
      <dc:creator>RTSLVU</dc:creator>
      <dc:date>2016-12-07T15:42:15Z</dc:date>
    </item>
    <item>
      <title>Re: write 2D data array to spreadsheet with good alignment</title>
      <link>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3555195#M994716</link>
      <description>&lt;P&gt;Hi RTSLVU,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;it's a real problem when people start to create &lt;A href="https://ni.lithium.com/t5/LabVIEW/Write-2D-Array-of-string-in-a-text-file/m-p/3555018#M994669" target="_self"&gt;double posts like LLX did&lt;/A&gt;…&lt;/P&gt;</description>
      <pubDate>Wed, 07 Dec 2016 15:46:46 GMT</pubDate>
      <guid>https://ni.lithium.com/t5/LabVIEW/write-2D-data-array-to-spreadsheet-with-good-alignment/m-p/3555195#M994716</guid>
      <dc:creator>GerdW</dc:creator>
      <dc:date>2016-12-07T15:46:46Z</dc:date>
    </item>
  </channel>
</rss>

