NLog time formatting

后端 未结 3 1045
一整个雨季
一整个雨季 2021-02-06 21:10

How do I write a layout for NLog that outputs time with milliseconds like this 11:32:08:123? I use ${date:format=yyyy-MM-dd HH\\:mm\\:ss} but I need mo

3条回答
  •  别跟我提以往
    2021-02-06 21:54

    ${longdate}
    

    Another alternative to the format suggested by harriyott is to use the ${longdate} renderer. It should automatically give you the precision you need.

提交回复
热议问题