"Unable to find an entry point"

G

Guest

I have created a very simple DLL in VC++ 6.0, then created a very simple App in VC++ 6.0 to use the DLL and this works fine
When I try to use the same DLL in C#, with DLLImport, the app finds the DLL just fine but then says
"Unable to find an entry point

When I try to use "user32.dll" everything works, but doesn't with my DLL

I am using .NET Framework 1.1 and VisualStudio .NET 2003 on Windows 2000 Pro
 
K

Klaus H. Probst

The export name may be mangled. Are you using a DEF file? Try to use dumpbin
/exports to see what the name of the function actually is.

In general you'll always want to use a DEF file.

--
____________________
Klaus H. Probst, MVP
http://www.vbbox.com/

Randy Crockett said:
I have created a very simple DLL in VC++ 6.0, then created a very simple
App in VC++ 6.0 to use the DLL and this works fine.
When I try to use the same DLL in C#, with DLLImport, the app finds the DLL just fine but then says:
"Unable to find an entry point"

When I try to use "user32.dll" everything works, but doesn't with my DLL.

I am using .NET Framework 1.1 and VisualStudio .NET 2003 on Windows 2000
Pro
 
G

Guest

The missing DEF file was the problem
Once I created a def file, then rebuilt my DLL, it worked fine in both VC++ 6.0 and C#.NE

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top