[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Mike Oliszewski

7/6/2002 5:21:00 PM

How can my c# dll find the directory it was installed into, such that it can
find other files. I'm trying to avoid requiring the installer to have to
put this into the registry.



2 Answers

Randy Charles Morin

7/7/2002 4:58:00 AM

0

You might try System.Reflection.Module.FullyQualifiedName
--
Randy Charles Morin
http://www....

Feel free to contact me by private email or messenger
morin_randy@hotmail.com
randy@kbcafe.com

"Mike Oliszewski" <mike_oliszewski@faxback.com> wrote in message news:Of7AlCQJCHA.2748@tkmsftngp13...
> How can my c# dll find the directory it was installed into, such that it can
> find other files. I'm trying to avoid requiring the installer to have to
> put this into the registry.
>
>
>


(Ping Zheng)

7/9/2002 2:52:00 PM

0

Hi Mike,

Please refer to the following code snip:

using System.Windows.Forms;
using System.Reflection;

...
Assembly SampleAssembly;
SampleAssembly = Assembly.GetExecutingAssembly();
Module mod = SampleAssembly.GetModule("xxx.dll");

MessageBox.Show(mod.FullyQualifiedName);

Please replace xxx.dll using your own DLL name.

Regards,
George