Registering a DLL in setup project

S

Simon Jefferies

Hello,

How can I register my own .NET DLL through a setup project? In other words
perform a regasm on a dll?

Thanks In Advance
Regards
Simon Jefferies
Tools Programmer, Headfirst Productions
mailto:[email protected]
-
 
D

DraguVaso

Is it only a DLL or a whole project including the dll??
In the second case the Setup will automaticly register the DLL.
In the first case I would make an application or .bat-file that registers
the DLL using regsrv32.exe

Hope this is enough?

Pieter
 
S

Simon Jefferies

Its a single DLL written in C# 2003, and is set to COM interop. Its a
dependency of one of my projects in the solution.

Is there anyway to register it through the setup project? or using a
installer class etc?

Regards
Simon Jefferies
Tools Programmer, Headfirst Productions
mailto:[email protected]
-
 
C

Chris Botha

Simon, in the setup project, in the properties for the DLL, look for
Register and select the vsdraCOMRelativePath.
 
F

Felix Wang

Hi Simon,

Thanks for posting. I would just like to confirm that you are actually
exposing a .Net assembly for COM use. Is this correct?

If this is the case, you may try using the
System.Runtime.InteropServices.RegistrationServices.RegisterAssembly()
method in an Installer class, or use Process.Start to launch the RegAsm.exe
directly.

You may need to pass the path information of your installed assembly
([TARGETDIR]) into the custom action, so that you can locate it and
register it:

http://msdn.microsoft.com/library/?url=/library/en-us/vsintro7/html/vxgrfCus
tomActionDataProperty.asp?frame=true

I hope the information is useful to you.

Regards,

Felix Wang
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 
S

Simon Jefferies

Thanks for your reply,

Yes, I am trying to expose a .NET assembly for COM usage. I will try the
method you mentioned about an installer class.

Many Thanks
Simon Jefferies
Tools Programmer, Headfirst Productions
mailto:[email protected]
-
 
S

Simon Jefferies

Hello,

How do I add an entry to the Windows Recent Documents list?

Thanks in advance,
Regards
Simon Jefferies
Tools Programmer, Headfirst Productions
mailto:[email protected]
 
F

Felix Wang

Hello Simon,

You may put a LNK file under the "%userprofile%\Recent" folder. But I don't
think it is recommended to manipulate this folder.

Regards,

Felix Wang
Microsoft Online Partner Support
Get Secure! - www.microsoft.com/security
This posting is provided "as is" with no warranties and confers no rights.
 

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