OLE Event handler parameters passed by reference as OSUint8
How are OLE event handler parameters extracted from OSUint8's?
Some event handlers receive parameters that are instances of OSUint8. How can these parameters be manipulated?
OSUint8 instances are used to handle parameters that are passed by reference. The selectors in OSPtr can be used to extract the address or data pointed to by the passed pointer.
For example, to extract the 32-bit integer referenced by an OSUInt8 instance:
osUInt8Value := (theIntParm int32At: 0).
To change the integer stored in an OSUint8 instance:
theIntParm int32At: 0 put: 12.
" To dereference a pointer to a pointer to an automation object, use code like that below "
OleAutomationObject forDispatch: (OSIDispatch address: (data uint32At: 0)).