2

I have published a console application through .Net Core2, and copied the output folder with EXE file on server.

If I double click and execute it is running all fine. But when I am scheduling it though task scheduler it is giving error - 0XC0000005

Any idea what needs to be fixed, or how to troubleshoot this more.

I did try to recreate it from the Administrator account too, but same issue.

A Developer
  • 1,001
  • 3
  • 12
  • 32

2 Answers2

3

Setting the - Start In value did the job for me.

A Developer
  • 1,001
  • 3
  • 12
  • 32
  • Thanks that helped me. I had tried everything else, but when I ran across this I thought why not, nothing else works. Quite weird. – Breadtruck Jul 01 '18 at 06:31
  • 1
    Dang, took me a while to realize I didn't copy the path, in fact I was duplicating an existing process pointing at a different configuration and I forgot the path. Thanks – Maximiliano Rios Dec 03 '20 at 13:32
2

It appears that .Net Core console app needs to run with the optional path so it can find the appsettings.json if you are using one.

Schedule a .Net Core console application on windows using Task Scheduler

Edit Action

Breadtruck
  • 1,943
  • 5
  • 25
  • 39