How can you retrieve the SMTP information from the web.config?

Discussion in 'ASP .Net' started by VickZaro, Apr 5, 2006.

  1. VickZaro

    VickZaro Guest

    How can you retrieve the SMTP information from the web.config?

    <system.net>

    <mailSettings>

    <smtp from="">

    <network host="relais.aol2.com" password="please" userName="username" />

    </smtp>

    </mailSettings>

    </system.net>
     
    VickZaro, Apr 5, 2006
    #1
    1. Advertisements

  2. VickZaro

    Guest Guest

    I typically place my keys in the AppSettings section.

    Then you can retrieve the keys using
    System.Configuration.ConfigurationSettings.AppSettings.Item
     
    Guest, Apr 5, 2006
    #2
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.