Results 1 to 6 of 6

Thread: [2005] Always use same settings

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Mar 2006
    Posts
    263

    [2005] Always use same settings

    I have a bunch of default user settings that can be changed from my program. The problem I have is that depending on how I start my program, I get a completly different set of settings.

    For example, I run my program from the IDE and set a setting to "A".
    If I quit and run the same program but as the compiled version in debug/bin, my setting is different than "A". This is very confusing because each test produces a different result, because the different versions of my program all keep a seperate set of settings.

    Is there a way to have a single common set of settings base for a single program?

  2. #2

  3. #3
    PowerPoster 2.0 Negative0's Avatar
    Join Date
    Jun 2000
    Location
    Southeastern MI
    Posts
    4,367

    Re: [2005] Always use same settings

    I assume you are storing your settings in some sort of XML or ini file. If you add the file to your project you can set a property on the file to Copy To Output Directory.

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Mar 2006
    Posts
    263

    Re: [2005] Always use same settings

    I use My.Settings, the settings being defined directly in the Properties page of my project.

  5. #5
    I'm about to be a PowerPoster! Hack's Avatar
    Join Date
    Aug 2001
    Location
    Searching for mendhak
    Posts
    58,333

    Re: [2005] Always use same settings

    I would suggest storing them external to your program. I use a settings table in my backend database, but Negative0's suggestion of an XML file or an ini file would work just as well.

  6. #6

    Thread Starter
    Hyperactive Member
    Join Date
    Mar 2006
    Posts
    263

    Re: [2005] Always use same settings

    Anyone have a good example on how to store program settings in a XML file using VB 2005?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width