Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / March 2005

Tip: Looking for answers? Try searching our database.

HOWTO: Call a Managed DLL from MFC C++ Code

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Morefeldt - 11 Mar 2005 10:19 GMT
Hi!

I have done exactly like stated in 'HOW TO: Call a Managed DLL from Native
C++ Code' from Knowledge Base, but in my MFC application I have implemented
the tmain section in it's own MFC class. All is looking good until a call to
interfaced Method is done, then I recieve a negative HRESULT. Why?

Best regards,
Bertil Morefält
ismailp - 13 Mar 2005 17:18 GMT
can you please provide a sample? did you compile your MFC application
with /clr?

i have a quick and dirty sample for you, but it does not use MFC or
interfaces. please be more clear about the problem.

Ismail
Fredrik Wahlgren - 13 Mar 2005 22:47 GMT
> Hi!
>
[quoted text clipped - 5 lines]
> Best regards,
> Bertil Moref??lt

Exactly what is the value of the HRESULT? If you convert it to hexadecimal,
you can search for it on google.

/Fredrik
ismailp - 15 Mar 2005 00:48 GMT
One "awkward" question; did you call CoInitialize() in that thread?
Does the object require MTA?

Ismail

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.