Click to See Complete Forum and Search --> : dllregisterserver entry point is not found
cobraeye
January 27th, 2003, 12:04 PM
hi,
Recently, I upgraded VB6 project to VB.Net. After that I can sucessfully compile the project and generate a DLL file in the bin folder, but when I try to use regsvr32 command to register the DLL, I got error saying "DllRegister Server Entry Point is not found".
And I cannot remove it from memory, if I want to use my old DLL.
Can anyone help me ?
DSJ
January 28th, 2003, 10:44 AM
.NET DLLs don't need to be registered.
cobraeye
January 28th, 2003, 11:57 AM
thanks for replying, but I cannot call the classes i defined in DLL from ASP any more, like I used to use Server.CreateObject("***") to create those server objects, but now my asp doesnt recognize this any more.
DSJ
January 28th, 2003, 01:58 PM
Ok, you'll have to register your DLL for com-interop then (build a COM wrapper for your .NET DLL). Under Project... Properties... Configuration Properties... Build, make sure the "Register For COM Interop" Checkbox is chosen.
cobraeye
January 28th, 2003, 02:07 PM
yes I did that. Then What should i do ? Register the DLL in Bin folder? I tried that as well. Still same error msg as I described in my original post. I checked boxes for Generating debug info, register for interop, enable build warnings and debug constant,
DSJ
January 28th, 2003, 02:16 PM
One the developement machine this should happen automatically, but on other machines you'll need to copy the DLL and .TLB file to the machine and then register (with regsvr32) the TLB file, NOT the DLL.
cobraeye
January 28th, 2003, 02:40 PM
ok, it does have a TLB file and when I use regsvr32, it says "XXXXX" is not an executable file and no registration helper is registered for this file type.
Thanks
DSJ
January 28th, 2003, 02:55 PM
Oops... been a while since I did this. Take a look at RegAsm.exe in the help. I believe you run this on the DLL file.
cobraeye
January 28th, 2003, 05:29 PM
I really appreciate your helps, I tried regasm as you instructed, and I can register that DLL now. But none of my class is available to be call from ASP. Meanwhile I am spending on this, I was wondering why Microsoft made things so complex for us? :mad:
DSJ
January 29th, 2003, 08:10 AM
Well, they're moving away from COM. If you ditched ASP and went with ASP.NET then you'd have no trouble calling the original .NET DLL.
cobraeye
February 3rd, 2003, 09:49 AM
Thanks, and now I want to go back to VB6 with my old DLL, I can compile it, but I cannot register my old DLL now. I think the .Net Version of DLL is residing in the memory. Do you know how to remove it? It says in the popbox when i did regsvr32 ... /u to use pview to detect and remove it, But I cannot find anything from pview.
Any idea?
potimus
April 10th, 2003, 10:07 AM
You can try unregistering it with Regasm.exe /unregister
cobraeye
April 10th, 2003, 12:30 PM
thanks for the reply, I used that to remove the DLL from the memory finally. But do u know after I upgrade the DLL to .Net, how can I make my ASP to use that DLL? Because when I do server.createobject it doesnt seems to be able to location my DLL
thanks
potimus
April 10th, 2003, 02:24 PM
No, I am trying to do the same thing. I can make it work on my Developer Machine, but not on my clients. I will post another reply when I figure it out. Please let me know if you figure it out.
My guess is that I need to use the GacUtil.exe but it is not on my client machines. I copied it over and it says that it is missing a dll.
MSvcrt70.dll I think is the one it told me it was missing.
Thanks
ipsteal
June 2nd, 2003, 10:53 AM
hey, i think i am having a similar problem with my program
i tried doing the Properties->Build Checkbox for register for COM Interop, but it is disabled so I can't check it.
When I run my program I get this popbox:
-----------------------------
An unhandled exception of type 'System.Reflection.TargetInvocationException' occurred in system.windows.forms.dll
Additional information: Unable to get the window handle for the 'AxTextBox' control. Windowless ActiveX controls are not supported.
-----------------------------
The code that is highlighted green is:
<code>
Friend Class frmXXXXX
</code>
I dont even know where to start!
Thank you,
IpSteal
kiransattenapalli
August 2nd, 2005, 06:19 AM
thanks for the reply, I used that to remove the DLL from the memory finally. But do u know after I upgrade the DLL to .Net, how can I make my ASP to use that DLL? Because when I do server.createobject it doesnt seems to be able to location my DLL
thanks
Hi
I too have same problem here.
Please inform me how you have Unregistered the dll .
Thank you
cobraeye
August 2nd, 2005, 08:09 AM
Actually it is about how to create a .NET DLL that can be used in ASP/VB. I found an article a while back and I tried to find it for you but unsuccessful. You can try to google it. Basically the steps involve
1. create GUID for your .NET DLL
2. use regasm.exe /tlb to register and unregister your DLL.
Good Luck
kiransattenapalli
August 2nd, 2005, 08:28 AM
Thanks,
When I try to Unregister, Its saying "....Consider using PView to Detect and remove it.."
Inform me How to detect and remove dll using Pview..
Thanks
dsparti
May 28th, 2009, 05:42 PM
The problem with registering a .Net object for COM interop is COM doesn't know where to find your DLL even after you register it. You must add the CodeBase registry entry which points to your DLL's location. The easiest way to do that is with an installer. Build an installer, extract the registry information, then add the CodeBase. Most installers will allow you to use a variable for this purpose so if the user installs the DLL to a different folder, the CodeBase will always point to the correct location. For example, in InstallAware, on the Registry tab, you can click the Import button which allows you to browse to your DLL. Once you select it, it will automatically import the registry settings for you. However, you must still add the CodeBase with code similar to this: Key = CodeBase Value = $TARGETDIR$
Here's something else to keep in mind. When creating a DLL for COM interop, there can only be one public class with a single, non-parameterized entry point. Be sure to mark any other classes or functionality you don't wish to expose as Internal (C#) or Friend (VB).
You also might want to specify the COM interface. That allows you to assign dispatch ID's to each property and method. This is important in case you ever change things. COM doesn't guarantee the order in which things are registered but if you specify an interface, you can control it so if you add new functionality, you don't break existing objects that use your DLL (i.e. DLL hell).
I realize that it'll take some research into creating an installer and/or creating a COM interface but I leave that as an exercise for you. I just wanted to point out the fact there is more to writing a COM object in .Net than appears at first.
codeguru.com
Copyright Internet.com Inc., All Rights Reserved.