?
Solved

Calling a vb.net dll from a vb6 app

Posted on 2006-11-01
3
Medium Priority
?
365 Views
Last Modified: 2012-05-05
We have a legacy vb6 application and want to expand iots functionality by creating a dll "ITS32.dll" in vb.net and calling it from vb6. I created a .net controlLibrary project and built a beginning dll. I ran it through tlbexp.exe, registered it with regasm.exe, and copied both the ITS32.tlb and ITS32.dll files to the System32 folder. I tried to add the dll to the vb6 project references but it would only accept the tlb. I created a declare statement in the vb6 project to identify the dll sub routine "createForm." My vb6 project has just a command button to call the dll sub. I get an error "Can't find dll entry point createForm in ITS32."

What advice do you have for me?
0
Comment
Question by:ZuTrekker
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 63

Accepted Solution

by:
Fernando Soto earned 2000 total points
ID: 17851592
Hi ZuTrekker;

I think you will find what you are looking for here.

How to call a Visual Basic .NET or Visual Basic 2005 assembly from Visual Basic 6.0

http://support.microsoft.com/kb/817248

Fernando
0
 

Author Comment

by:ZuTrekker
ID: 17852052
Well, that kb was very helpful. I copied the example exactly and now get an error message "Cannot create a file when that file already exists." That comes up on the "Set myObject = New TestProj.COMClass1" statement.
0
 

Author Comment

by:ZuTrekker
ID: 17852146
OK, I got past that. Now I get the same message on the line that reads "MsgBox myObject.myFunction" which seems weird because myFunction appears when the period is pressed.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Since .Net 2.0, Visual Basic has made it easy to create a splash screen and set it via the "Splash Screen" drop down in the Project Properties.  A splash screen set in this manner is automatically created, displayed and closed by the framework itsel…
It’s quite interesting for me as I worked with Excel using vb.net for some time. Here are some topics which I know want to share with others whom this might help. First of all if you are working with Excel then you need to Download the Following …
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses
Course of the Month11 days, 9 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question