System.Configuration.appsettingReader returns weird error

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • RD

    #1

    System.Configuration.appsettingReader returns weird error

    This code builds without errors, the line is in my declaration section of my
    form.yet when I execute it I get an unhandled error.

    Weird thing is I been testing this app all day yesterday, made no changes to
    my dev machine and now all of a sudden it goes out to lunch.

    Anybody have any ideas what that cryptic error means and what to do with it?

    Thanks for any help

    RD

    Private configurationAp pSettings As System.Configur ation.AppSettin gsReader =
    New System.Configur ation.AppSettin gsReader


    An unhandled exception of type 'System.Configu ration.Configur ationException'
    occurred in system.dll

    Additional information: Only elements allowed


  • Larry Lard

    #2
    Re: System.Configur ation.appsettin gReader returns weird error


    RD wrote:[color=blue]
    > This code builds without errors, the line is in my declaration[/color]
    section of my[color=blue]
    > form.yet when I execute it I get an unhandled error.
    >
    > Weird thing is I been testing this app all day yesterday, made no[/color]
    changes to[color=blue]
    > my dev machine and now all of a sudden it goes out to lunch.
    >
    > Anybody have any ideas what that cryptic error means and what to do[/color]
    with it?[color=blue]
    >
    > Thanks for any help
    >
    > RD
    >
    > Private configurationAp pSettings As[/color]
    System.Configur ation.AppSettin gsReader =[color=blue]
    > New System.Configur ation.AppSettin gsReader
    >
    >
    > An unhandled exception of type[/color]
    'System.Configu ration.Configur ationException'[color=blue]
    > occurred in system.dll
    >
    > Additional information: Only elements allowed[/color]

    Sounds like your .config file may be malformed in some way?

    --
    Larry Lard
    Replies to group please

    Comment

    • RD

      #3
      Re: System.Configur ation.appsettin gReader returns weird error

      Thanks, it was. Forgot to remove an end of comment mark.
      Chalk it up to experience ;-) but I wish the error messages would give a
      better idea exactly where to look.
      Again, Thanks a lot.


      "Larry Lard" <larrylard@hotm ail.com> wrote in message
      news:1116436945 .853814.168800@ g14g2000cwa.goo glegroups.com.. .[color=blue]
      >
      > RD wrote:[color=green]
      > > This code builds without errors, the line is in my declaration[/color]
      > section of my[color=green]
      > > form.yet when I execute it I get an unhandled error.
      > >
      > > Weird thing is I been testing this app all day yesterday, made no[/color]
      > changes to[color=green]
      > > my dev machine and now all of a sudden it goes out to lunch.
      > >
      > > Anybody have any ideas what that cryptic error means and what to do[/color]
      > with it?[color=green]
      > >
      > > Thanks for any help
      > >
      > > RD
      > >
      > > Private configurationAp pSettings As[/color]
      > System.Configur ation.AppSettin gsReader =[color=green]
      > > New System.Configur ation.AppSettin gsReader
      > >
      > >
      > > An unhandled exception of type[/color]
      > 'System.Configu ration.Configur ationException'[color=green]
      > > occurred in system.dll
      > >
      > > Additional information: Only elements allowed[/color]
      >
      > Sounds like your .config file may be malformed in some way?
      >
      > --
      > Larry Lard
      > Replies to group please
      >[/color]


      Comment

      Working...