[racket] ffi/com->typeconlict?

From: murat demirtas (heraklea at gmx.de)
Date: Thu Jan 24 05:21:55 EST 2013

Hello friends,

during getting a property I get an typconflict.

[code_begin]
#lang racket/base
(require ffi/unsafe
ffi/unsafe/com)
(define MSIFILE "D:\\_Setups\\7z920-x64.msi")
(define INSTALLER (com-create-instance "WindowsInstaller.Installer"))
(define DB (com-invoke INSTALLER "OpenDatabase" MSIFILE 0))

(define VIEW (com-invoke DB "OpenView" "SELECT Name FROM _Tables"))

(define RECORD (com-invoke VIEW "Execute"))
(set! RECORD (com-invoke VIEW "Fetch"))


;(com-get-property RECORD "FieldCount")
(com-get-property RECORD "IsNull")

;(define s (com-get-property RECORD "StringData"))
[code_end]

The "FieldCount" Property is getting 1
and "IsNull" or "StringData" gives:

com-get-property: failed for "IsNull" (80020005; Typkonflikt.) or
com-get-property: failed for "StringData" (80020005; Typkonflikt.)

so whats wrong here? The MDSN says it is an property an getting property on com in racket is trivial like above code shows, I think. 


Yours,


Posted on the users mailing list.