One place to start is by Googling "$app_name object model". The (full) help for most Microsoft applications includes this information, often disguised as instructions on use of Visual Basic for Applications or VBScript. These reference guides usually are not installed by default during the typical installation. They can be added later by rerunning the setup program with the custom install option. Also, one can often start the application in question, and select Tools/Macros/Visual Basic Editor, then View/$app Explorer, and the API should be within a click or two more.
You can also record a macro and then examine the code.
To record a macro
To view a recorded macro
How to Obtain Built-In Constant Values for an Office Application
The article http://support.microsoft.com/support/kb/articles/Q239/9/30.ASP describes how to obtain the constant values for Office applications from type library files. Here's an example of how to do it in Tcl.
Load the tcom extension.
% package require tcom 3.8
Read the type library file.
% ::tcom::import $pathToOfficeDirectory/excel9.olb Excel
The ::tcom::import command put the constant values into some arrays. It returns the namespace where it created the arrays.
% info vars ::Excel::* (many array names listed) % parray ::Excel::XlRowCol ::Excel::XlRowCol(xlColumns) = 2 ::Excel::XlRowCol(xlRows) = 1
By using optcl you can browse the interfaces of loaded com objects with:
package require optcl tlview::refview .ref tlview::loadedlibs .libs