473,320 Members | 2,146 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Cannot add a reference of a dll developed in C# into VB 6.0

Hi People,

I have been trying to add a reference of a dll created in C# to VB 6.0. It
just does not accept it. Any ideas.

Thanks
Vivek
Nov 16 '05 #1
4 1383
Vivek Sharma wrote:
Hi People,

I have been trying to add a reference of a dll created in C# to VB 6.0. It
just does not accept it. Any ideas.

Thanks
Vivek


You have to turn it into a COM object first.

Have a look at this link on CodeGuru :

http://www.codeguru.com/vb/gen/vb_ge...cle.php/c8269/

David.
Nov 16 '05 #2
You have to turn it into a COM object first.

Have a look at this link on CodeGuru :

http://www.codeguru.com/vb/gen/vb_ge...cle.php/c8269/

Also make sure that you change the assembly version number to a fixed
number...

Initially it is something like
[assembly: AssemblyVersion("0.0.*")]

On each build the build number is increased and then you have to
reselect the new Dll reference from within VB.

Change the version to
[assembly: AssemblyVersion("0.0.1")]

and this problem will be gone.
Jamie
Nov 16 '05 #3
Hi Vivek,

Register for COM Interop

In the solution explorer, right on your solution and choose properties.

Under the configuration properties --> Build

set the Register for COM Interop from false to true...

Then you are ready to use in VB6.

Have fun.

Cheers.

Regards,
Chua Wen Ching
visit us at http://www.necoders.com

"David McClarnon" wrote:
Vivek Sharma wrote:
Hi People,

I have been trying to add a reference of a dll created in C# to VB 6.0. It
just does not accept it. Any ideas.

Thanks
Vivek


You have to turn it into a COM object first.

Have a look at this link on CodeGuru :

http://www.codeguru.com/vb/gen/vb_ge...cle.php/c8269/

David.

Nov 16 '05 #4
Thanks. I tried building the project it gives me an error...

COM Interop registration failed. Type library exporter can not load required
library MSCOREE.TLB

Please help
"Chua Wen Ching" <ch************@nospam.hotmail.com> wrote in message
news:F7**********************************@microsof t.com...
Hi Vivek,

Register for COM Interop

In the solution explorer, right on your solution and choose properties.

Under the configuration properties --> Build

set the Register for COM Interop from false to true...

Then you are ready to use in VB6.

Have fun.

Cheers.

Regards,
Chua Wen Ching
visit us at http://www.necoders.com

"David McClarnon" wrote:
Vivek Sharma wrote:
Hi People,

I have been trying to add a reference of a dll created in C# to VB 6.0. It just does not accept it. Any ideas.

Thanks
Vivek


You have to turn it into a COM object first.

Have a look at this link on CodeGuru :

http://www.codeguru.com/vb/gen/vb_ge...cle.php/c8269/
David.

Nov 16 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Jim Campbell | last post by:
Suppose I wanted to a class to contain a pointer, but I didn't want to make the copy constructor or assignment operator reinitialize this pointer. (Think of a class that contains an mmapped pointer...
0
by: Dave Lessard | last post by:
Within my group of developers we have a list of library components we develop and continuously enhance and upgrade. We don't have source control (that's a bit of a sore issue for me) but when an...
5
by: Alper AKCAYOZ | last post by:
Hello Developers, I have developed Server and Client applications that are communicating by TCP/IP sockets. My application is developed on Visual C++ .NET Standard v2003 Windows Forms. When one of...
8
by: baustin75 | last post by:
Posted: Mon Oct 03, 2005 1:41 pm Post subject: cannot mail() in ie only when debugging in php designer 2005 -------------------------------------------------------------------------------- ...
3
by: Lance Geeck | last post by:
There seems to be a file called Reference.vb that is generated based on a web service that I developed. I changed the name of a public function in the web service and when I try to call it, I am...
1
by: Jeff | last post by:
Hello, I have developed a library of controls but for the life of me cannot get ToolboxBitmapAttribute to work -- my image simply will not display in the toolbox of any project using my...
2
by: semedao | last post by:
Hi All, I developed Outlook add-in with VS 2005 , everything work fine , until the machine reboot unnormally , when I opened the solution again many projects was not there ! (I have more then...
2
by: =?Utf-8?B?cmVk?= | last post by:
Hi Friends, We recently deployed our application to production and I am experiencing the below error message. Cannot access a disposed object named "System.Net.TlsStream" The error occurs...
275
by: Astley Le Jasper | last post by:
Sorry for the numpty question ... How do you find the reference name of an object? So if i have this bob = modulename.objectname() how do i find that the name is 'bob'
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.