[racket] Com Service with ffi
Ok,
I make this:
(define _ULONG _ulong)
(define _CATID _GUID)
(define _REFCATID _GUID-pointer)
(define-cstruct _CATEGORYINFO ( [catid _CATID]
[lcid _LCID]
[szDescription (_array _short 128)]))
(define IID_ICustomList
(string->iid "{3039E12D-6CEF-4F91-AE9B-E609481C8824}"))
(define-com-interface (_ICustomList _IUnknown)
([Next/ci (_mfun (_ULONG = 1)
(catinfo : (_ptr o _CATEGORYINFO))
(got : (_ptr o _ULONG))
-> (r : _HRESULT)
-> (cond
[(zero? r) catinfo]
[(= r 1) #f]
[else (windows-error "Next/ci
failed" r)]))]
[Skip _fpointer]
[Reset _fpointer]
[Clone _fpointer]))
But I dont know how to use it, especially in invoking the desired function??
Yours,