10-12-2010 05:24 AM
Hello,
I designed a Excel-WorkSheet, defined the printing area and saved it as file.xlsx.
Then - in LabView - I open Excel and write some data to the cells (OpenExcel, OpenBook, OpenSheet, SetCellValue). But when I print now the excel-sheet via Lab View (Invoke Node -> Print Out) the print area is lost. This means I have a lot of white space on my print. Why does this happen?
Thanks for Help
Gabriel
10-13-2010 03:54 AM
Hello Gabriel,
It would be nice to get some more details, could you post your VI? Did you use any examples delivered with LabVIEW?
You can also post your VI in the forum as PNG-Image, which can be sitll used in LabVIEW:
10-13-2010 06:54 AM
Hello Ilja,
I used examples I saw in a book (for open Excel an write values).
Here are my VIs. The first is an extract of my main-VI.
An here the Sub-VI to write the Data to Excel (Icon A(8)->Excel)
Could it be a problem that I'm working with xlsx-files?
Gabriel
10-13-2010 09:07 AM - edited 10-13-2010 09:08 AM
Hello Gabriel,
there should not be any problems with the .xlsx format, as it is just a newer Excel format allowing you to save files with more than 256 columns/rows
Error -2146827284 Occurs When Using Append Table to Report.vi
http://digital.ni.com/public.nsf/allkb/DBDA2D8E71F7F721862571FB005E17D7?OpenDocument
I still have no idea what result with "a lot of white space on my print" you get. Please attach a working excerpt with the affected VIs and some test data. I have no time to build it on my own. As written above, VI Snippets would be fine (if you posess LabVIEW 2009 and higher).
Creating VI Snippets in LabVIEW 2009
10-13-2010 10:38 AM
Hello Ilja,
I'm sorry, I'm using LabView 8.6.
I append you a VI with the corresponding code.
When you open the attached Excel-File an watch the Print Preview, you see it like this (the printing area are only the yellow cells)
After running the VI and inserting some text,
the print Preview is lost, because you see more.
Thanks
Gabriel
10-20-2010 03:01 AM
Hello Gabriel,
I had no time to have an in-depth look at the vi. But as far as I have seen, working with the standard .xls format works as expected.
10-20-2010 03:44 AM
Hello,
Where have you seen that it works as expected?
I added my VI aggain (with the used librarys from the examples). The content is very simple. I open the excel-file, write into one cell and then take a look on the prinitng preview.
It would be nice if you can take a look at the problem. or should I contact the support via phone?
Thanks
Gabriel
10-29-2010 09:52 AM
Hello fischberg,
as far as you have a support contract with National Instruments, you can call our hotline 089 7413130, by the way I am from department responsible for Germany, Austria and Switzerland.
Telling your Service Request Nummer 950908 you will be redirected to me if possible.
Nevertheless your VI worked when saving to the .XLS format.
03-27-2012 03:18 PM
Hey, guys.
I've got the same problem with LabVIEW 2009.
After LabVIEW opens my Excel files the print_area disappears from my templates.
So I have to add it manually:
I know it's too late, but how did you solve it?
05-24-2024 02:19 AM
Hello guys !
I have the same problem with LabVIEW 2023 and MS office 365. For one prinded page with data, I get 3 blank pages...
The printing area become bigger, instantly after it gets into the "create report" VI.