Guy,
Thanks for your response! I've been requesting help for over a week on this topic, and you?re the only reply I've had. I've
purchased the book you recommended and I'll pick it up in a couple of hours. Hopefully it will provide the answers. There is another
book I've found online called COM and .NET Interoperability, by Andrew Troelsen, which also looks good, but this is not out for 1
month.
Thanks again!
Pete
From: "Guy Harwood" <guy@h...>
Date: Tue 12/Mar/2002 09:48 GMT
To: "Professional Windows Forms" <pro_windows_forms@p...>
Subject: [pro_windows_forms] RE:using .NET components in COM apps
Hi Pete,
Rockford Lhotka has written a wrox book (Professional Visual
Basic Interoperability-COM and VB6 to .NET)pretty much
covering what your talking about. He's also done an article
based on the books content for fawcette that you can
read at
http://www.fawcette.com/vsm/2002_04/magazine/features/rlhotka/default.as
p
Hope this helps
Guy Harwood
Research & Development Consultant
www.hcs-ltd.co.uk
-----Original Message-----
From: Professional Windows Forms digest
[mailto:pro_windows_forms@p...]
Sent: 12 March 2002 00:09
To: pro_windows_forms digest recipients
Subject: pro_windows_forms digest: March 11, 2002
-----------------------------------------------
When replying to the digest, please quote only
relevant material, and edit the subject line to
reflect the message you are replying to.
-----------------------------------------------
The URL for this list is:
http://p2p.wrox.com/list.asp?list=pro_windows_forms
PRO_WINDOWS_FORMS Digest for Monday, March 11, 2002.
1. using .NET components in COM apps
----------------------------------------------------------------------
Subject: using .NET components in COM apps
From: "Peter Dobson" <pete@e...>
Date: Mon, 11 Mar 2002 20:25:26
X-Message-Number: 1
Has anyone ever managed to succesfully use VB.NET forms or VB.NET
UserControls in a COM app?
Problem1:
If the vb6 app calls a method in the NET component which displays a .net
form, it displays correctly, but when I press tab, the focus never
leaves the control with the focus on the .net control.
It seems that Microsoft removed the ablity to create .net components
that could be used as vb6 usercontrols after beta1 of .net.
Problem2:
When I'm debugging in the VB IDE, I get a Run-time error '-2146233054
(80131522)' if the NET dlls are not in the same directory as VB6.exe.
Fine I thought, I'll place a copy of them there and great, it works. The
next big problem is when my vb ocx component (which instanciates my net
component) is instanciated from a c++ app, I get Run-time error
'-2146233082 (80131506)' even if I copy my NET dlls into the c++ apps
exe folder! I've tried placing copies in System32 and no difference.
Unfortunately our .net screens will have to be displayed in our parent
company's MDI form which loads ocx components that it reads in .ini
files
Any help solving this problem would be greatly received! I am trying to
establish the feasability of using .net for our new project, and if I
can't get over these hurdles soon, we will reluctantly have to decide on
vb6 instead of vb.net.
---
END OF DIGEST
$subst('Email.Unsub').
_______________________________________________________________________
Never pay another Internet phone bill!
Freeserve AnyTime, for all the Internet access you want, day and night, only £12.99 per month.
Sign-up at http://www.freeserve.com/time/anytime