Link to home
Start Free TrialLog in
Avatar of RandyTommy
RandyTommy

asked on

web installation of ActiveX written in C#; Can't register DLL

I found a simple article on making an ActiveX that includes input/output parameters.  Exactly the structure I need. It is located at:
http://dotnetslackers.com/articles/csharp/WritingAnActiveXControlInCSharp.aspx

But it won't work from Javascript without being Registered in the system.  A Microsoft article at:
http://support.microsoft.com/kb/280579
states "The ActiveX control must be packaged as an Installer Package (.msi) file instead of as a standard Internet Explorer cabinet (.cab) file."
So I downloaded the free MakeMSI program and spent the day learning to use it.  However, while installing the .msi file it created, I got an error message that
my DLL could not be installed.

As a test, I tried installing the DLL by hand, which gave me the error message that the "dllregisterserver entry point was not found."
Googling the term "dllregisterserver", I found:
http://msdn.microsoft.com/en-us/library/dd376682(v=vs.85).aspx
which explains how to include it in C++ DLLs.  However, I'm using C#, which can't find either "STDAPI" nor "AMovieDllRegisterServer2", essential parts of the example shown.

I've been unable to find any information on doing this in C#.  So I'm totally lost at this point.

Maybe all the above isn't really the best way?  Going back to the beginning, my basic question is still, how can I write ActiveX's in C# that can be installed in client machines from my website?
ASKER CERTIFIED SOLUTION
Avatar of Craig Wagner
Craig Wagner
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of RandyTommy
RandyTommy

ASKER

Thank you for the detailed, step-by-step answer.  That's information worth keeping!  Although in my case, I'm attempting to steer away from making a website depend on .NET.  So I'm still looking for a siimple answer.  I did find two pages that addressed my "install dll" problem, stating simply "You can't do it".  Not my way at least. Success would require YOUR way.  :)