01-18-2012 10:15 AM
Hallo,
I've been searching the forums and trying out new stuff in Labview 2010 for some time, but I have yet to find a good solution.
The thing is I have an EXCEL template, which contains cells with different sizes and text with different sizes and fonts.
I would like to append text (Array to spreadsheet, then into the Write to text file) or the array (with strings) itself to this EXCEL template, starting at the end (bottom line).
For some reason, when I use the normal Open > Set File Position > Write to text file > Close functions I can only use the "Start" option @ Set File Position. If I use the "End" option the data does not get written in the file.
The only way of doing this, to my knowledge, is to use the Report Generation Toolkit in Labview. The only problem I have with this is that you need to set a window size (minimized, normal or maximized) and I would like to run EXCEL as a proces only (in the background, so no window popup).
Is there a way to keep the data in the template file, with it's sizes and fonts, and append data in the background (proces instead of window)?
Thanks.
01-19-2012 08:27 AM
Dear Warrian,
There is an ActiveX component which can arrange this; when we chose the Excel Application reference we can control the property visible. Please find the attached example; this example hides excel and makes it visible every half second. If you run your task manager you will see that Excel never disappears from your applications list (so it is running hidden).
I hope this will help you a little bit further,
Best regards,
01-19-2012 08:33 AM
Thank you for your reply, but I have just found the solution myself 🙂
I was able to root the window option completely out of the Report Generation Toolkit subVI, so I am now using the standard blocks with a minor adjustment. Deep down the subvi it all came down to removing window from an invoke / property node (can't remember which) and making the visibility always false.
So if anyone wants to do this aswell, just keep on double clicking on the subvi's that use the blue line (window mode) and remove it completely by removing the property / invoke method and all it's dependants and making the visibility always false (and removing the broken lines in the top VI's).
01-19-2012 01:03 PM
It is not wise to change VIs from toolkits. What do you think will happen if you need to reinstall the toolkit? What do you think will happen if you need to install this on another computer?
01-19-2012 02:10 PM
@Warrian wrote:
Hallo,
The only way of doing this, to my knowledge, is to use the Report Generation Toolkit in Labview. The only problem I have with this is that you need to set a window size (minimized, normal or maximized) and I would like to run EXCEL as a proces only (in the background, so no window popup).
Is there a way to keep the data in the template file, with it's sizes and fonts, and append data in the background (proces instead of window)?
Thanks.
Yes, with the New Report VI in the Report Generation Toolkit, set the Window state to "Unchanged." Excel will not open (unless already opened), but will run in the background.