dll configuration

  • Thread starter Thread starter Cetel Sistemas
  • Start date Start date
C

Cetel Sistemas

Hi,

I`d like to know if it is possible to configure a dll dinamically. I want to
change the dll.config values and make the dll take those new values.

If this is possible I'd like to go a bit further. I wrote a dll in c#
(usercontrol) which I use as an active X in asp.NET:

<object id="ActiveX" classid="HDControlesX.dll#HDControlesX.AccesoAdmin"
style="width: 150px; height: 100px"></object>

Id like to be able to configure this dll in the server without having to
compile the library again. At the moment, I have to compile the library in
order to make the settings changes work, but what I need is just to change a
file and that the dll takes the new arguments.

Thanks in advance
 
Generally, it's standard practice to have settings for an dll sent into it
either via parms in the constructor of the class or properties. DLL's should
not have a configuration file. This way they can be easily used by mutiple
applications.

David

======================================
David McCarter [Microsoft MVP]
www.dotNetTips.com
David McCarter''''s .NET Coding Standards available at:
http://www.cafepress.com/geekmusicart.1654787045
 
If you want fully dynamic assemblies, consider looking into Reflection. With
Emit, you can write a complete assembly from scratch. I am not sure about
changing the assembly in the way you envision, however.

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://gregorybeamer.spaces.live.com/lists/feed.rss

*************************************************
| Think outside the box!
|
*************************************************
 
Back
Top