Microsoft SDK for Java

Implementing IDispatch

The Microsoft virtual machine implements IDispatch automatically for almost all Java objects. This means that a tool, such as jactivex, is no longer necessary simply to script a Java object from an Automation controller such as Visual Basic or Microsoft® Visual Basic® Scripting Edition (VBScript). The Microsoft VM also provides an implementation of IDispatchEx, which is required for COM object interoperability with some Microsoft scripting technologies.

To implement a simple Automation object in Java

  1. Implement the Java object and compile it.

  2. Register it using javareg.

  3. Ensure that the Java class is visible in the CLASSPATH environment variable.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.