472,799 Members | 1,763 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

dotNet dlls in VB6?

OK, this is a rather strange request

Is it possible to use dot-net dlls in VB6 projects?
Is anyone doing this or is this completely useless?



Nov 21 '05 #1
4 1381

It is absolutely possible to use .NET dlls in VB6 projects. However,
you have to design your classes correctly so that they work with COM interop
correctly. Basically this means defining interfaces using Automation
compatable types, and then implementing them.

For more information, check out the tutorial in the .NET framework
documentation titled "COM Interop Part 2: C# Server Tutorial", located at
(watch for line wrap):


Hope this helps.
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com
"Peter Plumber" <Kl******@gmxdot.net> wrote in message
OK, this is a rather strange request

Is it possible to use dot-net dlls in VB6 projects?
Is anyone doing this or is this completely useless?



Nov 21 '05 #2
One way would be to expose the managed code(.Net) functionality thru
COM for the unmanaged world(VB). There are possibly better ways than
this as this would require code change in .Net modules (comvisible

Ajay Kalra

Nov 21 '05 #3
"Peter Plumber" <Kl******@gmxdot.net> schrieb:
Is it possible to use dot-net dlls in VB6 projects?


M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Nov 21 '05 #4
This is definitely supported, and is pretty straightforward if you're using
the Visual Studio IDE.

Here's an overview
1. Create a VB class library project.
2. Add a new item using the "Com class" template.
3. Compile your project.

What this does is create the class, apply a comclass attribute, set the
correct GUID's for com interop, creates a VB6 class which wraps the VB.Net
class, registers the vb6 class.

Here's some docs you can look up:

Did this give you the info you needed?

Date: Mon, 21 Mar 2005 17:02:06 +0100
From: Peter Plumber <Kl******@gmxdot.net>
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.6) Gecko/20040113X-Accept-Language: en-us, en
MIME-Version: 1.0
Subject: dotNet dlls in VB6?
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit
Message-ID: <#X**************@TK2MSFTNGP12.phx.gbl>
Newsgroups: microsoft.public.vb.general.discussion,microsoft.p ublic.dotnet.languages.vb,
microsoft.public.dotnet.languages.csharpNNTP-Posting-Host: 83-64-137-178.work.xdsl-line.inode.at
Lines: 1
Path: TK2MSFTNGXA02.phx.gbl!TK2MSFTNGXA01.phx.gbl!TK2MSF TNGP08.phx.gbl!TK2MSFTNGP1
2.phx.gblXref: TK2MSFTNGXA02.phx.gbl microsoft.public.dotnet.languages.vb:266599 microsoft.public.dotnet.languages.csharp:314725
microsoft.public.vb.general.discussion:542781X-Tomcat-NG: microsoft.public.dotnet.languages.vb

OK, this is a rather strange request

Is it possible to use dot-net dlls in VB6 projects?
Is anyone doing this or is this completely useless?



Nov 21 '05 #5

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

Similar topics

by: Alex | last post by:
Dear colleagues I am going to deploy dotnet framework in our company. For this I need to do a risk assessment of dotnet framework. Thus I have following question: Is there an available risk...
by: assi | last post by:
Hello all We are developing a large dotnet application, which includes ~ 120 assemblies. (total size of all binaries is ~ 20MB). Our application also references the following dotnet assemblies:...
by: Peter Plumber | last post by:
OK, this is a rather strange request Is it possible to use dot-net dlls in VB6 projects? Is anyone doing this or is this completely useless? thx Peter
by: Jozsef Bekes | last post by:
Hi All, I have a question about how to use the final product I build with dotnet. I used to work with VC++ 6, and there was an option in the project settings to either use the MFC dlls or build...
by: Takeshi | last post by:
Hi All, I am impressed with the aesthetic (UI) appeal of DotNet, but not by much else, like it's new fangled languages etc... I have a legacy C++ 3tier application, which uses C++ DLLs. I would...
by: gg | last post by:
My standard version of dotnet 2003 basic does Not have vbc.exe have class library template produce dll when outputtype is changed to classlib for .vbproj it seems that standard version is not...
by: Jim Horvath | last post by:
I know how to create exe applications in dotnet that use functions supplied by pre-existing dlls. How do you turn that around? I want to create an exe program that will be the pre-existing piece....
by: Peted | last post by:
Hi, im hoping someone cane provide or point to a definitive accurate explantion of dotnet compilation when run and the best way to optimise peformace when dotnet code is run first time and...
by: Derek Hart | last post by:
I am unclear about what all the requirements are to call a simple vb.net application, installed in the GAC, from COM (such as writing vba in Word to call the dotnet dll). I believe I have...
by: erikbower65 | last post by:
Using CodiumAI's pr-agent is simple and powerful. Follow these steps: 1. Install CodiumAI CLI: Ensure Node.js is installed, then run 'npm install -g codiumai' in the terminal. 2. Connect to...
by: erikbower65 | last post by:
Here's a concise step-by-step guide for manually installing IntelliJ IDEA: 1. Download: Visit the official JetBrains website and download the IntelliJ IDEA Community or Ultimate edition based on...
by: kcodez | last post by:
As a H5 game development enthusiast, I recently wrote a very interesting little game - Toy Claw ((http://claw.kjeek.com/))。Here I will summarize and share the development experience here, and hope it...
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Sept 2023 starting at 18:00 UK time (6PM UTC+1) and finishing at about 19:15 (7.15PM) The start time is equivalent to 19:00 (7PM) in Central...
by: Taofi | last post by:
I try to insert a new record but the error message says the number of query names and destination fields are not the same This are my field names ID, Budgeted, Actual, Status and Differences ...
by: DJRhino1175 | last post by:
When I run this code I get an error, its Run-time error# 424 Object required...This is my first attempt at doing something like this. I test the entire code and it worked until I added this - If...
by: lllomh | last post by:
Define the method first this.state = { buttonBackgroundColor: 'green', isBlinking: false, // A new status is added to identify whether the button is blinking or not } autoStart=()=>{
by: lllomh | last post by:
How does React native implement an English player?
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...

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.