Solved

Register Dll created with wizard

Posted on 2000-03-30
2
341 Views
Last Modified: 2008-03-04
I create a Dll using Wizard (A dll that export same symbols). I succeed to call a function of that Dll from a C++ console application. I didnt register the Dll. I want to call a function of the Dll from VBP. for that i should register it. I tried to run RegServ32 with MyDll.dll but i get an error:
"MyDll.dll" was loaded, but the DllRegisterServer entry point was not found. DllRegisterServer may be exported, or a corrupt version of MyDll.dll may be in memory. Consider using PView to detect and remove it."
0
Comment
Question by:oshra
2 Comments
 
LVL 2

Accepted Solution

by:
arikka earned 10 total points
ID: 2668696
Don't use in Wizard WIN32 DLL as Project Type, instead use ATL COM Wizard
type. Next use Server Type as DLL.
Build process automaticly will create
DllRegisterServer exportable entry and register your Dll.

If you do not want to have your Dll as COM server, you do not need to register
regualr Dll at all. Just make sure that
function you want call are exportable
(or in DEF file, or something like that
 __declspec( dllexport ) int func())).

In order to call them from VB just use :

Declare Function func _
Lib "mydll.dll" ( _
    ByVal a As Integer, _
    ByRef b As Integer _
) As Integer




0
 

Author Comment

by:oshra
ID: 2668934
I chose to use Dll and not ATL Dll in purpose. it was a mistake to think that i should register that. i solved my problem by creating a DEF file.
Thanks anyway.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
Written by John Humphreys C++ Threading and the POSIX Library This article will cover the basic information that you need to know in order to make use of the POSIX threading library available for C and C++ on UNIX and most Linux systems.   [s…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…

863 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

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now