Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. using configuration settings in a dll.

using configuration settings in a dll.

Scheduled Pinned Locked Moved C#
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    User 2657147
    wrote on last edited by
    #1

    I have a dll (a control derived from Label) and I would like to use the simple key/value configuration settings provided by App.config (or similar file). Visual Studio gladly creates this resource for me, encouraging me to think a dll can have its own settings. This statement will always get a setting from the exe, what ever exe is using the dll. string dbText = ConfigurationSettings.AppSettings["Foxpro_template"]; How can I have config settings for the dll control? Lastly, I realize the configuration manager will manage 'machine' wide setting for me. That is nice but it always wants to place the user and machine settings under a 'mydocuments' folder. I would like to keep the entire suite under one folder so a user could duplicate an install with a simple copy and paste command. That is I want to keep machine and user settngs under folder C:\myproduct not c:\mydocuments. Any suggested readings or ideas? Thanks Phil

    L 1 Reply Last reply
    0
    • U User 2657147

      I have a dll (a control derived from Label) and I would like to use the simple key/value configuration settings provided by App.config (or similar file). Visual Studio gladly creates this resource for me, encouraging me to think a dll can have its own settings. This statement will always get a setting from the exe, what ever exe is using the dll. string dbText = ConfigurationSettings.AppSettings["Foxpro_template"]; How can I have config settings for the dll control? Lastly, I realize the configuration manager will manage 'machine' wide setting for me. That is nice but it always wants to place the user and machine settings under a 'mydocuments' folder. I would like to keep the entire suite under one folder so a user could duplicate an install with a simple copy and paste command. That is I want to keep machine and user settngs under folder C:\myproduct not c:\mydocuments. Any suggested readings or ideas? Thanks Phil

      L Offline
      L Offline
      led mike
      wrote on last edited by
      #2

      Did you try ExeConfigurationFileMap[^]

      led mike

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups