Participant
980 Points
323 Posts
Oct 23, 2020 09:27 AM|Jerry Cai|LINK
Hi,Yossu
Yossu However, the log file did not contain the message I added.
I tested your code and reproduced the problem, then solved it by changing the code in appsettings.Devlopment.json to this:
{ "Logging": { "LogLevel": { "Default": "Debug", "Microsoft": "Warning", "Microsoft.Hosting.Lifetime": "Information" } } }
Result:
Best Regards,
Jerry Cai
Participant
980 Points
323 Posts
Re: log4net logger not writing my logs to file, but ASP.NET log messages are written
Oct 23, 2020 09:27 AM|Jerry Cai|LINK
Hi,Yossu
I tested your code and reproduced the problem, then solved it by changing the code in appsettings.Devlopment.json to this:
{ "Logging": { "LogLevel": { "Default": "Debug", "Microsoft": "Warning", "Microsoft.Hosting.Lifetime": "Information" } } }
Result:
Best Regards,
Jerry Cai