原位置:
www.authorware-amy.com/Newsletter/January_2003_4.htmYou can extend the capabilities of Authorware pieces built for the PC by using ActiveX controls. ActiveX controls are third-party components built so that they can be included in other Windows applications. Some examples include the windows controls, the Windows Media Player, and the Flash Player ActiveX control (not to be confused with the Asset Xtra).
Up until Authorware 6 was released, you could not use most ActiveX controls inside Authorware. This is because most ActiveX controls contain objects, and Authorware was not able to "talk" to these objects.
For example, the Microsoft Agent ActiveX control contains a Characters object. In Authorware 5.2 and before, there was no way to address this object to load the individual character, much less issue commands to the character itself.
The Authorware 6.0 and 6.5 ActiveX Xtras contain a new method, #callstring, that gives authors a way to access properties and methods of objects within a given control. For instance, code to load a character into a MS Agent ActiveX control might look like:
Command := "Characters.Load ¬
('John','"^FileLocation^"John.acs')"
CallSprite(@"Agent Sprite", #CallString, Command)
For good background articles on using ActiveX controls in Authorware, check out Apurva Lawale's Tips and Articles page. The Gantek Multimedia Downloads page has a great example of how to use the new #callstring method with the Microsoft Agent ActiveX control.
Did you know?
WinCtrls.u32 is based on the Microsoft Common controls, but is not identical to them. The u32 is what is known as a "wrapper," which encapsulates the functionality of the controls and makes them easier to use. For instance, you can draw an unknown number of WinCtrls on the screen, whereas you would have to have one ActiveX control for each windows control if you were to use ActiveX directly for it.
In addition, there are several controls, such as the Date and Time Picker, not included in WinCtrls.
www.authorware-amy.com/Newsletter/January_2003_4.htm