app.config

J

JonMYates

Hello all,

I have a web application that references a number of dll's that I have
included in my solution. I'm writing a dll that I will use to send out
mails (mailer.dll). I'd like to keep this fully encapsulated and so
I've put the smtp etc details in the projects app.config, however,
from within a class in the mail.dll project I try to call one of the
app.configs keys, but it just seems to be looking in the applications
web.config - which is kinda understandable, but I'd really like to
keep thing encapsulated so how can I get values from the app.config
file instead?

Thanks all,

JY
 
K

Kevin Spencer

The web.config file is the equivalent of the app.config file in an ASP.net
application. If you use the ConfgurationManager to read the config file, it
should be transparent to the app.

--
HTH,

Kevin Spencer
Microsoft MVP

Printing Components, Email Components,
FTP Client Classes, Enhanced Data Controls, much more.
DSI PrintManager, Miradyne Component Libraries:
http://www.miradyne.net
 

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

Members online

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top