>is there a windows API telling me if a certain word document is open ?
>
>Peter
You may check this
Problem with closing Excel opened by automation Thread #
1232734 recent thread where I was dealing with a similar problem, though for Excel.
I also discussed it in another forum and found, that if you have a reference to your Excel (word) object, the simplest way to bring it to front, is to set its WindowState to maximize.
#define xlMaximized -4137
#define xlMinimized -4140
#define xlNormal -4143
loExcel.WindowState = xlMaximized
Idea by Vladimir Maximov in
http://forum.foxclub.ru/read.php?29,278870,page=2 and
http://forum.foxclub.ru/read.php?32,177182,258927#msg-258927 (in Russian)
If it's not broken, fix it until it is.
My Blog