Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Interapplication Communication /
Chapter 10 - Scripting Components / Scripting Components Reference
Optional Scripting Component Routines / Manipulating Dialects


OSAAvailableDialects

You can use the OSAAvailableDialects function to obtain a descriptor list containing information about each of the currently available dialects for a scripting component.

FUNCTION OSAAvailableDialects
               (scriptingComponent: ComponentInstance;
                VAR resultingDialectInfoList: AEDesc): OSAError;
scriptingComponent
A component instance created by a prior call to the Component Manager function OpenDefaultComponent or OpenComponent (see page 10-4).
resultingDialectInfoList
The returned descriptor list.
DESCRIPTION
Each item in the list returned by OSAAvailableDialects is an AE record of descriptor type typeOSADialectInfo.

CONST typeOSADialectInfo = 'difo';
Each descriptor record in the descriptor list contains, at a minimum, four keyword-specified descriptor records with the following keywords:

CONST
   keyOSADialectName       = 'dnam';{used with descriptor record }
                                    { of any text type, such as }
                                    { type typeChar}
   keyOSADialectCode       = 'dcod';{used with descriptor record }
                                    { of type typeShortInteger}
   keyOSADialectLangCode   = 'dlcd';{used with descriptor record }
                                    { of type typeShortInteger}
   keyOSADialectScriptCode = 'dscd';{used with descriptor record }
                                    { of type typeShortInteger}
Rather than calling OSAAvailableDialects to obtain complete dialect information for a scripting component, it is usually more convenient to call OSAAvailableDialectCodeList to get a list of codes for a scripting component's dialects, then call OSAGetDialectInfo to get information about the specific dialect you're interested in.

RESULT CODES
noErr0No error
errOSASystemError-1750General scripting system error
badComponentInstance$80008001Invalid component instance

Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996