user.config issues RRS feed

  • Question

  • I'm using C# Express. I am not using Click-Once to install and distribute. I am manually copying right now for testing until I can build a WIX based msi file.
    (When I tried Click-Once to deploy, a user.config was stored in AppData\Local\Username\appname\...., but Click-Once is unusable, since I use an URL handler to relaunch the app, which needs an exe in a reliable path) 

    Scope is User.
    My app Properties Resources management is set to Icon and manifest.

    When it runs in the debugger, it saves the settings to:
    I copy all my code to my test box to a single folder. Run it. It fails, since no values are being saved.
    So do I need to put a copy of user.config in AppData\Local\... or will it create one if I  set something to point my app to a specific user\AppData folder?
     Any idea on how to do that?


    Rick Hantz

    • Edited by RickHan Thursday, March 1, 2012 5:00 AM rewrite
    Thursday, March 1, 2012 12:30 AM

All replies

  • Hi Rick Hantz,

    How did it fail? Could you please share more details on that part?

    Best regards,

    Friday, March 2, 2012 3:26 AM
  • It wasn't writing to the user.config.

    I recomplied several times, and it finally started writing to it.

    How would I change the name of the path, at least the parts that are like Url_tkliqijmduf200v0qh5puafyy4dsysaa??

    Rick Hantz

    Friday, March 2, 2012 3:34 AM
  • Hi RickHan,

    I don't think you need to deal that path by yourself.

    Could you please show us your code of saving the config?

    Min Zhu [MSFT]
    MSDN Community Support | Feedback to us

    Monday, March 5, 2012 6:59 AM