This sample is located in \Samples\ActiveX\SampleBean.
Description
Using the Sample
Key Project Files
Technologies Demonstrated
This JavaBean handles simple events and can be added as a control to a Microsoft® ActiveX® container, such as Microsoft® Visual Basic® 5.0. The Bean's textToDraw and textColor properties can be set from Visual Basic. The Microsoft virtual machine (Microsoft VM) uses introspection and provides the automatic mapping so that Visual Basic recognizes these as properties of the Bean. The Bean's returnTheDate method can also be called from Visual Basic. The Microsoft VM automatically does all the "wiring" necessary for the somethingHappened method of the SampleBeanEvent to be caught in Visual Basic
You must have Visual Basic 5.0 or later installed to use this sample.
To compile the sample
Use Nmake.exe to compile the makefile in the \Samples\ActiveX\SampleBean directory.
To use the sample
This class defines the SampleBeanEventListener interface, registers listeners, and enables and processes mouse events. It also contains methods for getting and setting the textToDraw and textColor properties, and returning the date.