Reputation: 8064
I'm struggling to get a simple COM Server running in Visual D 2010. These are the steps I did so far:
dserver.d
into dllmain.d
chello.d
and dserver.def
into the solution's source folder, as well as advapi32.lib and ole32.lib from the <D install dir>\dmd2\windows\lib
. dserver.def
into dll.def
, overwriting existing project's file.chello.d
and dllmain.d
(originally dserver.d
) as written on this forum threadregsvr32 COMServer.dll
returns these four message boxes:then
then
and finally
I am still unable to access the COM object from VBA. And referencing the DLL directly (by Browse... button and pointing to the COMServer.dll) fails with "Can't add a reference to the specified file."
Upvotes: 1
Views: 200
Reputation: 25595
I took another look at the forums and the problem with the samples seems related to TLS on Windows XP. I posted a (somewhat hacky) solution to it here:
http://forum.dlang.org/thread/[email protected]?page=2
Upvotes: 1
Reputation: 6774
I can't provide you with a working answer. It looks like this was a year ago, I was trying to get an example of using a COM server working. This uses Juno (not 64bit ready), has nothing to do with Visual D, and most importantly I couldn't get to work. The issue I hit was related to registering the server ("side-by-side configuration is incorrect").
My qualifications for COM are all there in the history of Juno (so not much of any). If you're more familiar with COM you may get further, if it doesn't compile for the latest DMD let me know (2.064 isn't out yet anyway).
Upvotes: 0