I am afraid you can't do what you're trying to do directly with WriteExcel. The Excel data format isn't your typical Unix-like data stream that can be written to by one process and read by another.
If I were doing this, I would consider splitting the program into two pieces.
One piece would write the data that comes out of your equipment control to some kind of simple log file format. This would run continuously throughout your data run. If you do this right it will be very simple, so you won't run a big risk of losing data or crashing your run because of a software error.
The second piece would read that log file format and use WriteExcel to pop out an up-to-the-minute copy of your spreadsheet. It would run to completion quickly, rather than having to wait for your equipment. You could run this anytime you need to see results. For example, you might run it every hour during your seven-hour run to see how things are going.
In reply to Re: Open Excel while writing & Save file
by Ollie Jones
in thread Open Excel while writing & Save file
by perly_newbie
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |