LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

LV 7.1.1 PDA modules & excel issues

Hey everybody, i've attached a VI i wrote, all it does is add a number and stores it into an array then i write to a file. I tried changing the extension to .xls for the type of file and then I try to open it with excel in the pda and i get an error of invalid type. On the other hand, if i change the extension to .rtf it opens fine in word... If my code is messy, Please excuse me for that, I am new to LV and the whole concept of data-flow programming. SO in a nutshell, i want to write to a file and open it with excel... thank you!
0 Kudos
Message 1 of 5
(3,716 Views)
Hello GHernandez,
 
The problem doesn't lie with your VI.  You can verify this by running your code on your development machine.  If you do this, you will note that you can change you code to save to test.xls and if you were to double click on this file, Excel would render it.  Now, I think the reason why you are seeing this behavior is because your PDA has a flavor of Excel called Pocket Excel which does not directly read .xls files.  Instead, it reads the Pocket Excel Workbook format (.pxl)
 
If you open up ActiveSync and navigate to the Options»Rules»Conversion Settings»Desktop to Device tab, you should see under the Desktop computer convertible file types dialog an entry for Microsoft Excel Worksheet.  If you select that worksheet, you should see that .xls desktop computer files are going to be converted to .pxl files to work on your mobile device.
 
 
So you might want to modify your VI to save the file as test.pxl and then open this file on your PDA.
 
Hope that helps. 

Message Edited by Wendy L on 10-20-2005 04:54 PM

Wendy L
LabWindows/CVI Developer Newsletter
Message 2 of 5
(3,707 Views)
I think their is an issue with the array to spreadsheet string. I get garbage for some reason even though i changed the extension to .pxl. Which is odd, whenever i changed the extension to .rtf it opens fine in pocketword.
0 Kudos
Message 3 of 5
(3,678 Views)
I've attached a jpeg to show what i've done.

Message Edited by GHernandez on 10-21-2005 02:21 PM

0 Kudos
Message 4 of 5
(3,674 Views)
Hello GHernandez,
 
The problem does not lie with the Array to SpreadSheet String VI.  This VI simply save data to a spreadsheet string (a generic tab delimited string that can be opened in a text editor).  Many common applications can open this kind of generic file and render it appropriately.  That is why you see appropriate behavior when you save this output string to a file with a .xls or .rtf file format. 
 
On the other hand, there are difference between the .xls and .pxl file format.  The detailed specification would be on Microsoft's support webpage.  The issue is that there are enough differences between these file format such that you cannot simply save a tab delimited file with the .pxl extension and open it in Pocket Excel.  That is why ActiveSync automatically converts .xls files located on your development machine to .pxl files for use on your PDA.  There are specific changes that occur during this conversion that are not accounted for when you simply save a generic spreadsheet with a .pxl file format using the Array to SpreadSheet String VI and Write File VI. 
 
To reiterate though, when you write data to a file with the Write File VI, you are not converting the data to a specific file format.  It just so happens that in many cases you can save simple text files with the .xls or .rtf formats and they can be opened with other applications.  The same is true for the .html file format. 
 
So, I would suggest saving your files to a file format that is supported on your development machine and your PDA (such as the .rtf or .txt) then open these files in Pocket Excel, if that is possible.  Once these files are open in Pocket Excel, you can then save them as .pxl files from this application.
 
Hope that helps.
Wendy L
LabWindows/CVI Developer Newsletter
0 Kudos
Message 5 of 5
(3,657 Views)