[uuid(01234567-89ab-cdef-0123-0123456789ab), version(1.0), helpstring ("Test OLE automation")] library OleTest { importlib("STDOLE.TLB"); [uuid(d0bed0be-d000-beee-d000-d0bed0bed0be), odl, oleautomation, dual, helpstring("Name/value pair")] interface TestObj : IDispatch { [propget, helpstring("Name of quantity")] HRESULT name([out,retval]BSTR *name); [propput] HRESULT name([in]BSTR name); [propget, id(0), helpstring("Value (default property)")] HRESULT value([out,retval]double *value); [propput, id(0)] HRESULT value([in]double value); [helpstring("square of value")] HRESULT square([out,retval]double *square); }; [dllname("OleTest.dll")] module utilities { [entry("?NewTestObj@@YGPAUTestObj@@PAGN@Z"), helpstring("Create & initialise TestObj")] TestObj * pascal NewTestObj([in]BSTR name, [in]double value); }; };