PDA

View Full Version : Unable to copy excel spreadsheet to another spreadsheet



Shadow_x27
06-10-2009, 07:59 AM
Hello everyone! Brand new to the forums so please go easy on me if I don't follow "procedure". lol Thanks! :hi:

I have a VB program that will open another application. Inside this application I can generate an excel spreadsheet.

My goal is copy the information generated from the spreadsheet to a new one. Then do calculations, formatting, etc.

However, the problem that I have is that the excel spreadsheet generated by my application won't open until after my VB code has finished running. This makes it tricky because I can't save the active window, copy the ranges, or anything. I have thought about making two scripts: you click one to get the spreadsheet and then once it's open you click the other one. However, I would like it to be one script, one click is possible. The reason for this is that the program has the possibility to leave my office and so it needs to be able to function without instruction.

That's about all I have, so if you need more information, please let me know.
Thanks in advance!

mdmackillop
06-10-2009, 12:32 PM
Hi Shadow,
Welcome to VBAX
You could use OnTime to trigger a second macro without user intervention.
Regards
MD