... sorry,
I hit the wrong button in the newsreader.
For controlling other applications from Word,
see getobject, createobject
for the clipboard
see
MSForms
Dataobject
GetFromClipboard
PutInClipboard
I don't know where to start.
Greetings from Bavaria, Germany
Helmut Weber, MVP
"red.sys" & chr(64) & "t-online.de"
Word XP, Win 98
http://word.mvps.org/
>Hi ANdy,
>what application?
[quoted text clipped - 24 lines]
>>
>>ANDy
Hi Helmut,
Thanks for your attempt to help.
> what application?
A dictionary application (Van Dale Groot woordenboek Engels-Nederlands).
The executable is `VDEN.exe'. I don't mention it because, to most people
in this group, it is unknown.
> What is it, that you want to do?
Select the text of all entries that I have entered myself, copy it to a
Word document, manipulate the text (manually or automatically), copy the
manipulated text back to the same dictionary application.
I need to activate this application and then, with sendkeys (since I
guess there is no other way) select, copy and past text.
>>I would like to open another application, open a dialog box
>>there and (with sendkeys) select and copy copy the contents of the box
[quoted text clipped - 10 lines]
>>
>>How can I copy info from and to the Windows clipboard in VBA?
Helmut Weber - 28 Feb 2005 17:10 GMT
Hi Andy,
if VDEN.exe is in no way programmable,
not to be seen anything like it in extras references,
then indeed for controlling it you may have to rely
on another program like Word and to use sendkeys.
Notoriously unreliable.
Close all other programs.
Disconnect from anything.
Activating any application is easy: shell(),
but could be done manually as well.
If, hopefully, Sendkeys is working at all,
then you wouldn't need the clipboard,
as you could send all letters to an inputbox or so
in VDEN.exe. If this fails only partly, you might try
to use the clipboard. For that, you need a reference
to the MSForms-Library, which, alas, might not to be
found in extras references, but is added automatically,
as soon as you have a userform somewhere in your VBA-code.
Just any userform, you don't have to use it.
Then you can create a dataobject and use methods like
putinclipboard.
Good Luck
Greetings from Bavaria, Germany
Helmut Weber, MVP
"red.sys" & chr(64) & "t-online.de"
Word XP, Win 98
http://word.mvps.org/
and - 28 Feb 2005 17:35 GMT
Hi Helmut,
Thanks for the extra info. I may decide to use macro mania to get the
job done, if the method you describe is that unreliable.
But I'll do some tests to see how things go.
Best regards,
ANDy