>Hi,
>
>Can someone post code as to how to bring an Excel window forward using api calls? My current code creates an Excel document, inserts all the data and then uses .Activate() which just activates it on the toolbar so that it is flashing - it does not actually bring it forward. I figure Win api calls would need to be used to do this.
>
>I have looked in the VFP Office automation book but the constants used are old and figure someone might have a nice function to do this.
>
>Thanks,
>Albert
If I recall correctly, try setting the Excel to minimized and then to maximize. I posted that code a while ago (originally from Russian VFP forum). Tried to search there now, but it's tricky.
UPDATE. Found it eventually (in Russian):
http://forum.foxclub.ru/read.php?29,557209,557261#msg-557261
If it's not broken, fix it until it is.
My Blog