Contents

AEPutParamPtr(_:_:_:_:_:)

Inserts data, a descriptor type, and a keyword into an Apple event or Apple event record as an Apple event parameter.

Declaration

func AEPutParamPtr(_ theAppleEvent: UnsafeMutablePointer<AppleEvent>!, _ theAEKeyword: AEKeyword, _ typeCode: DescType, _ dataPtr: UnsafeRawPointer!, _ dataSize: Size) -> OSErr

Parameters

  • theAppleEvent:

    A pointer to the Apple event to add a parameter to. See the Appleevent data type.

  • theAEKeyword:

    The keyword for the parameter to add. If the Apple event already includes an parameter with this keyword, the parameter is replaced.

    Some keyword constants are described in 1527206 Keyword_parameter_constants.

    See Aekeyword.

  • typeCode:

    The descriptor type for the parameter to add. For a list of AppleScript’s predefined descriptor types, see 1542788 Descriptor_type_constants. See Desctype.

  • dataPtr:

    A pointer to the data for the parameter to add.

  • dataSize:

    The length, in bytes, of the data for the parameter to add.

Return Value

A result code. See Result Codes.

Discussion

Thread safe starting in OS X v10.2.

See Also

Adding Parameters and Attributes to Apple Events and Apple Event Records