Thread: Compiler Error CS0116 in app.config

  1. #1
    Registered User GrumpyGreyGoat's Avatar
    Join Date
    Jun 2009
    Location
    North GA
    Posts
    3

    Question Compiler Error CS0116 in app.config

    I get this error when I build.

    I understand about scope and enclosing brackets, and I have read several posts for this compiler error on a few different forums, but they all show the error in the C# code, not the XML app.config.

    I had published the app, installed it, and run it, but it was named "WindowsFormsApplication1". I wanted to specify the name as something more specific, so I changed the Product Name under Project | Properties, and that's all I changed.

    Now I get this error.

    I've changed everything back, but I still get the error.

  2. #2
    Confused Magos's Avatar
    Join Date
    Sep 2001
    Location
    Sweden
    Posts
    3,145
    MagosX.com

    Give a man a fish and you feed him for a day.
    Teach a man to fish and you feed him for a lifetime.

  3. #3
    Registered User GrumpyGreyGoat's Avatar
    Join Date
    Jun 2009
    Location
    North GA
    Posts
    3

    Thumbs down Been there, done that

    That very page was one of the several I had already researched, as I mentioned, but it talks about the problem being in the C# code. My error message directs me to the app.config, which is XML.

    I was hoping someone had seen it in this context before.

    Thanks for the note.

  4. #4
    Frequently Quite Prolix dwks's Avatar
    Join Date
    Apr 2005
    Location
    Canada
    Posts
    8,057
    I have no idea what I'm talking about, but you may want to look at this link (which you've probably already seen anyway ...):
    App.Config
    dwk

    Seek and ye shall find. quaere et invenies.

    "Simplicity does not precede complexity, but follows it." -- Alan Perlis
    "Testing can only prove the presence of bugs, not their absence." -- Edsger Dijkstra
    "The only real mistake is the one from which we learn nothing." -- John Powell


    Other boards: DaniWeb, TPS
    Unofficial Wiki FAQ: cpwiki.sf.net

    My website: http://dwks.theprogrammingsite.com/
    Projects: codeform, xuni, atlantis, nort, etc.

  5. #5
    Registered User GrumpyGreyGoat's Avatar
    Join Date
    Jun 2009
    Location
    North GA
    Posts
    3

    Cool Close, but not quite

    I do not know what happened with my code. I probably inadvertently deleted one half of a pair of braces '[]' or parens '()' without realizing it, snooping around in the code just to look. A missing brace is what the MS site says probably causes this error, but the compiler should not point me to the XML file.

    I deleted the project and recreated it, clearly not an option if this happens in a large project with many forms and classes.

    Thanks for your efforts.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. added start menu crashes game
    By avgprogamerjoe in forum Game Programming
    Replies: 6
    Last Post: 08-29-2007, 01:30 PM
  2. Compiler Paths...
    By Cobra in forum C++ Programming
    Replies: 5
    Last Post: 09-26-2006, 04:04 AM
  3. C Compiler and stuff
    By pal1ndr0me in forum C Programming
    Replies: 10
    Last Post: 07-21-2006, 11:07 AM
  4. I can't get this new compiler to work.
    By Loduwijk in forum C++ Programming
    Replies: 7
    Last Post: 03-29-2006, 06:42 AM
  5. how to call a compiler?
    By castlelight in forum C Programming
    Replies: 3
    Last Post: 11-22-2005, 11:28 AM

Tags for this Thread