From what I read it appears, that enterprise library does not allow tokens in filename, which is very strange, because all other logging solutions do.
It's very confusing, I am definetly missing something. Cause I am not even able to specify Process name in flat or lolling file listener.
NLog
<target name="txtFile"
xsi:type="File"
fileName="${cached:cached=true:inner=${date:format=yyyy-MM-dd HH-mm-ss}}.txt"
layout="${longdate} ${level} ${message}"/>
Log4Net
<file type="log4net.Util.PatternString" value="~/App_Data/%property{LogName}" />
The only solution I know (excluding programmatic setup) now is using Environment Variables on Process Level
And to set those variables in code: