Hi =?Utf-8?B?SmFuZnJ5?=,
> In Windows XP, Word 2003 SP2, I use Task.Activate() to give focus to the Word
> window to show the document I've launched, but the Word-task doesn't activate
[quoted text clipped - 6 lines]
> However, if Word is not launched before, all works fine always, even with
> Active(True).
Mmm. Which programming language are you using? Please show us the code you use
to work with the Word application so that we can get an idea what's going on?
Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org
This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail :-)
Janfry - 15 Jun 2007 12:05 GMT
I'm using Java, with Jacob to communicate with Word
(http://sourceforge.net/projects/jacob-project/).
This does not work:
Dispatch.call(msWord.getWordObject(), "Activate");
Neither this:
Dispatch tasks = Dispatch.get(msWord.getWordObject(),
"Tasks").toDispatch();
Dispatch task = Dispatch.call( tasks, "Item", "Microsoft
Word").toDispatch();
Dispatch.put(task, "Visible", new Variant(true));
Dispatch.call(task, "Activate", new Variant(false));
Dispatch.put(task, "WindowState", new Variant(1)); //
dWindowStateMaximize
The Word is activated, but not opened, only blinking in the task bar.
Thanks,
> Hi =?Utf-8?B?SmFuZnJ5?=,
>
[quoted text clipped - 19 lines]
> This reply is posted in the Newsgroup; please post any follow question or reply
> in the newsgroup and not by e-mail :-)