control other applications

  • Thread starter Thread starter l. britton
  • Start date Start date
L

l. britton

i have an excel macro that has several variables with values
associated with them. I want to open another non office application
and send the variable values to that other application. the other
application was written in vba and shows on the macjine as xxxx.exe.
i can open the other application from the excel macro, but how do i
make it an object towhich i can send the data?
many thanks for any assistance.
 
Roedd said:
i have an excel macro that has several variables with values
associated with them. I want to open another non office application
and send the variable values to that other application. the other
application was written in vba and shows on the macjine as xxxx.exe.
i can open the other application from the excel macro, but how do i
make it an object towhich i can send the data?
many thanks for any assistance.

By "written in vba" I presume you mean VB4 or 5 or 6. In order to control
the application via OLE Automation (COM) the application would have to have
been written as an OLE Server (or ActiveX exe, as they became known). If it
wasn't, you're out of luck. In the VBE in Excel, select Tools | References
and scan the list for a reference to anything that looks like it could be
the other application. You might be lucky.

Otherwise you may have to resort to SendKeys or, possibly, sending Windows
messages (a kind of lower level sendkeys) to the other app.

--
Rob

http://www.asta51.dsl.pipex.com/webcam/

This message is copyright Robert Bruce and intended
for distribution only via NNTP.
Dissemination via third party Web forums with the
exception of Google Groups and Microsoft Communities
is strictly prohibited and may result in legal action.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top