home *** CD-ROM | disk | FTP | other *** search
/ AppleScript - The Beta Release / AppleScript - The Beta Release.iso / Development Tools / Unsupported Tools / Sample OSA Component / About OSASampleComponent next >
Encoding:
Text File  |  1992-11-25  |  1.7 KB  |  10 lines  |  [ttro/ttxt]

  1. About Sample OSA Components
  2.  
  3. The AppleScript component is an OSA component that implements the AppleScript scripting language. It is possible to have other OSA components that support other scripting languages. We have include here some other OSA components to illustrate the concept.
  4.  
  5. OSASampleComponent is a sample program on how to write an OSA Component. This is very preliminary; some of the details may be wrong and not all OSA calls are implemented. The only thing it does is to translate "one", "two", "three" to "1", "2", "3" etc. The source is included so that you can start to build your own OSA Component.
  6.  After you install the component, you can use it from Toy Surprise. You should be able to see it from the Default Component sub-menu of the Edit menu in Toy Surprise. If you choose it as the default component, all new scripts you compile will use the sample component instead of AppleScript. (Already-compiled scripts will continue to use the component they were previously compiled with.)
  7.  
  8. Also included is a program called DoScriptFromOSA that let you do a little more with some existing programs that support the "Do Script" ('dosc') Apple Event. It is an application and you do not need to install it. To talk to an application through DoScriptFromOSA, you drop your application (such as HyperCard and ToolServer) into DoScriptFromOSA to register it. (What's actually registered is a simple OSA component that runs scripts by sending them via DoScript events.) Then you can run it from Toy Surprise. For example, if you register HyperCard and select it as the default component, then you can type in HyperTalk commands in a Toy Surprise window. When it is executed, a DoScript command is sent to HyperCard and if there a result it is returned.
  9.  
  10. —Ed Lai