
JavaBeans Bridge for ActiveX v1.0 - September 97
Warning
The CLASSPATH/PATH requirements have changed dramatically since Beta 3,
please read the environment
settings for the bridge paragraph.
REPACKAGE ALL your JavaBeans with the new packager version. Do not
use old packaged JAR files, they will not be loaded any more by the bridge,
they reference classes that are obsoleted or renamed.
Requirements
-
Operating Systems
-
-
The following operating systems are supported on Intel processor
-
Windows NT 4.0
-
Windows 95 with Service Pack 1
-
-
Java Development Kit
-
-
The final version of the JDK 1.1 is the only one currently supported. Find
it at the Java
Development Kit Home Page. JDK 1.1.4 is recommended.
Installation
1. Files installation
-
Warning : The installation assumes the JDK 1.1 or later is installed
OR the bin directory added to the path.
-
Double click on the setup.exe and follow the instructions.
-
-
2. Try it out
-
One easy test to check your installation is to run the packager from the
desktop. Open the windows TaskBar, choose the ActiveX Packager For JavaBeans
icon from the program menu.
-
-
The following screen should appear :
-
3. Documentation
-
Look into your installation directory for a documentation on how to use
the ActiveX bridge and a quick example how to run it in Visual Basic. The
file is AXInstruct.ps (for PostScript) or .pdf (for Acrobat).
Tested Containers
-
The following ActiveX containers have been tested :
-
Visual Basic 4.0 Standard Edition
-
Visual Basic 5.0 CCE
-
Microsoft Office 95 (Word, Excel, PowerPoint)
-
Microsoft Office 97 (Word, Excel, PowerPoint)
In-place Document or ActiveX component
-
Internet Explorer 3.02, 4.0 (Preview 2 w/o shell integration)
-
Microsoft ActiveX ControlPad
-
Microsoft FrontPage 97
-
Delphi 2.0
-
MFC 4.2 or 5.0
Design Considerations
Although you don't need to code
the JavaBeans differently if you want to use it in the ActiveX bridge,
there are some considerations and advices you need to follow:
-
AWT events (like actionPerformed on a Button) can be forwarded to the ActiveX
bridge and hooked up to a script method, but remember that the event has
been fired by the AWT thread and therefore should not be blocked for a
long time by the scripting method. Otherwise the AWT thread gets confused
and you can hang the Java Virtual Machine. For example, if Visual Basic
enters debugging mode while receiving an AWT event, you should return to
design mode immediately rather than debug in running mode where you have
risks to confuse AWT.
-
If your JavaBean grows, consider providing a BeanInfo to describe your
bean. It prevents the ActiveX bridge from forwarding all AWT events and
supports all the java.awt.Component methods and properties.
-
To translate your .gif files, you can paint them as .bmp and configure
the Registry file as described in the documentation or use a shareware
product to do the translation for you.
-
The packager will create an instance of the Bean at packaging time, the
instantiation of this bean should not fail or generate exception in order
to correctly generate the OLE information about this bean.
-
Please report any bugs to JavaSoft.
Environment
variables used by the ActiveX bridge
The ActiveX bridge does not
require any environment variable.
The Java Development Kit
must have been installed with its correct installation setup OR the JDK
must be accessible through the PATH
The Bridge will look into
the registry to look at it's installation path to use the correct CLASSPATH.
If you move manually the bridge installation directory, please modify the
registry key :
HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Beans\ActiveX Brige\ActiveXHome
If you package some JavaBeans
and want to load the packaged jar file into the BeanBox you will need to
add the path to the bridge classes to the CLASSPATH before running the
beanbox. You can either modify the makefile that runs the beanbox or set
the environment variable CLASSPATH.
Given you installed the
ActiveX bridge in the c:\bdk\bridge, register the following CLASSPATH:
CLASSPATH =c:\bdk\bridge\classes
To register the CLASSPATH
on Windows 95, edit the autoexec.bat file and add the following statement:
set CLASSPATH = c:\bdk\bridge\classes
To register the CLASSPATH
on NT, log on as administrator, start the control panel, select the environment
tab and add a system variable CLASSPATH with the correct value.