Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ TheIDE » U++ TheIDE: Compiling, Linking, Debugging of your packages » Using COM object
Using COM object [message #15376] Fri, 18 April 2008 01:29 Go to next message
forlano is currently offline  forlano
Messages: 1182
Registered: March 2006
Location: Italy
Senior Contributor
Hello,

I'm trying to use an external library made by a COM object.
This is the first time I face such animal. It seems I must register it in some way. I remind to have seen a discussion about this topic in the past but I cannot find it with the search function.
In particular I would like to know if I can import it and how. In visual C++ the command seems to be
#import “<path>\my_library.dll”

Many thanks,
Luigi
Re: Using COM object [message #15379 is a reply to message #15376] Fri, 18 April 2008 09:27 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1182
Registered: March 2006
Location: Italy
Senior Contributor
forlano wrote on Fri, 18 April 2008 01:29

Hello,

I'm trying to use an external library made by a COM object.
This is the first time I face such animal. It seems I must register it in some way. I remind to have seen a discussion about this topic in the past but I cannot find it with the search function.
In particular I would like to know if I can import it and how. In visual C++ the command seems to be
#import “<path>\my_library.dll”

Many thanks,
Luigi


Is this http://www.ultimatepp.org/srcdoc$Core$DLI$en-us.html
what I am looking for a COM object?

Luigi
Re: Using COM object [message #15393 is a reply to message #15376] Sun, 20 April 2008 16:12 Go to previous messageGo to next message
tvanriper is currently offline  tvanriper
Messages: 85
Registered: September 2007
Location: Germantown, MD, USA
Member
I do not think so... the .dli mechanism looks to me as if it is intended to be used with arbitrary DLLs and the functions they expose.

I've bound to COM objects using Ultimate++ before, at my job. Basically, I sorta cheated.

I had another project in Microsoft Visual C++ that used the COM objects I wanted to use. These generated a .c and .h file that provided the bindings I needed for the COM object. I simply pulled these into my Ultimate++ project.

This said, I should think you ought to be able to use the #import trick if the DLL in question supports it. You'll need to include the right headers to make use of it (I can't recall what they are right now, and I'm at home... won't be back to work for a week or so). And, honestly, I haven't really tried it.
Re: Using COM object [message #15394 is a reply to message #15376] Sun, 20 April 2008 16:14 Go to previous message
tvanriper is currently offline  tvanriper
Messages: 85
Registered: September 2007
Location: Germantown, MD, USA
Member
I should be more specific...

The MIDL compiler generated the .c/.h files from another file in my Visual C++ project.

I don't know if Ultimate++ supports this very well, although you can use third-party tools in Ultimate++.
Previous Topic: custom buildsteps
Next Topic: Link error when using polymorphism
Goto Forum:
  


Current Time: Thu Mar 28 22:28:04 CET 2024

Total time taken to generate the page: 0.01690 seconds