locked
"Configuration system failed to initialize" RRS feed

  • Question

  • User-187731752 posted

    Hi,

    I have created a Windows Service and i am calling a web service method from my windows service.

    When i run my windows service, i am getting the below error

    "Configuration system failed to initialize"

    Note: The services are installed and my web service is running from Visual Studio (ASP.NET development server)

    Please help to fix this error.

    Wednesday, April 23, 2014 5:36 AM

Answers

  • User-187731752 posted

    Thank you All for the replies.

    The error is fixed. I had made some changes and reverted in config file, so i felt my config was not correct. What i did is recreated my project and did not make any changes to config file and it solved the problem.

    Thank you again.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, April 25, 2014 3:38 AM

All replies

  • User-718146471 posted

    The Age-Old mantra: post your code.  No more can a mechanic fix your car without seeing it, we cannot fix your code without seeing it either.

    Wednesday, April 23, 2014 8:01 AM
  • User-1454326058 posted

    Hi AshwiniSH,

    How do you call the web service in the Windows service?

    I think there are something wrong during call the web service, so the windows service is failed.

    I suggest that you could add the code to the try catch code block what is used to call the web service, then you could log the error message.

    After that you could check the error message.

    About how to log the error message in the windows service, please refer to:

    # Programming a Windows Service in C#

    http://devblog.grinn.net/2008/01/windows-services-in-c-part-1.html   

    If you still have the issue, please provide the detail code to us.

    Thanks

    Best Regards

    Thursday, April 24, 2014 4:19 AM
  • User465171450 posted

    You may also want to post in the WIndows forums over at MSDN since this has to do with a Windows Service, and they will have far more help with that. Even though it is calling a web service, I believe it has more to do with spinning up your windows service than it does with calling the web service. I've seen this error commonly with issues in the services app.config file.

    Thursday, April 24, 2014 4:09 PM
  • User-187731752 posted

    Thank you All for the replies.

    The error is fixed. I had made some changes and reverted in config file, so i felt my config was not correct. What i did is recreated my project and did not make any changes to config file and it solved the problem.

    Thank you again.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Friday, April 25, 2014 3:38 AM