From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how can i print an excel spreadsheet file by clicking a button on the front panel

i have designed a vi that logs data into an excel spreadsheet. i want to take print out of the file when the user clicks a button on the front panel. what to do if there is very large amount of data.
0 Kudos
Message 1 of 2
(2,300 Views)
Preet,

Printing the Excel sheet is just an ActiveX method call to print the worksheet. To add data to the worksheet, you already have the reference, just call a print method. As for handling large amounts of data, that is a vague question. The data will print how ever you placed it on the worksheet. If what you mean is that you don't want to print out 25 pages every time, the print method has options to only print specific pages or ranges. You may want to play around with a sample spreadsheet to learn the printing options. For help on the ActiveX functions, make sure you have the Visual Basic help installed for Excel.

Randy Hoskin
Applications Engineer
National Instruments
http://www.ni.com/ask
0 Kudos
Message 2 of 2
(2,300 Views)