API Calls / Application that controls 3rd Party Software

ss7thirty

Well-known member
Joined
Jun 14, 2005
Messages
455
Location
New Jersey, US
Programming Experience
5-10
I was looking for some information on how to write software that interacts with other software. Also, I was wondering if VB.NET is good for this. By "interacts" I mean I would like to pull information from the other program. Such as information in textboxes and the ability to click buttons. I would also like to be able to perform some other common tasks. I would know how to do this for internet explorer, and any office program but this is third party software.

I know that you can do this through the Windows API, but I also have heard that %75 of these API calls have been upgraded into .NET. What is the best way to go about writing an application that will be able to control another application?

If the API is the best way to go, does anyone have a good online resource for API functions? I have not been able to find one.
 
That does seem like it is a good resource. Their add-in is a little flakey but seems to work pretty good for inserting API calls. However, my knowledge on API is pretty null and this makes it a little hard. Would you happen to know which DLL I should import in order to do what I talked about above?

Thanks much!
 
Windows API documentation is a bit all over the place. There is not really any definitive resource, which is why a wiki like PInvoke.net is one of the better resource available. Generally you'll build up an understanding of what functions are available and what they do over time from different resources and help from other developers. I would suggest making as much use of PInvoke.net as you can, but also get the API Viewer and the API Guide. The guide will show you groups of functions with related functionality, so that gives you a place to start looking. Otherwise it's just down to searching the Web and posting specific questions on forums. Note that you should also make use of Spy++ (that comes with VS) and WinID to determine the properties of the windows you're trying to interact with.

When it comes to interacting with other applications the Windows API can let you do a great deal, but it can be tedious. Believe me, as I'm creating a replacement UI for a POS application at the moment. If you want to interact with IE or Office apps then that's a different story. They both expose an object model specifically designed to allow you to control them directly. You should search MSDN for more information. Search for office automation and you'll get plenty of info. For IE I guess you could use "automation" as a key word too but I'd just go to the index and drill down until I found information on the IE object model.
 
Thanks alot!

The pinvoke add in for visual studio is fairly helpful at time, a little flakey but that is just windows altogether it would only be right if their API documentation was like that.
 
Back
Top