If you are an emulation-only developer, please ignore this section. Log file names in emulation environments are named using web.config.
This section is for developers that have created a Inventu Viewer+ Screen Integration application with Inventu Viewer+ Studio--either a Web Services solution or Web UI solution, where new sessions are created in the solution framework rather than by a user connection to the FVTerm application.
There is a special method in the TaskSession.cs web service module for managing the name of the log files. This is a good place to also set the name of the log file so that the FVTerm web emulator logging functions can log to the same file as the web service (for each session).
It is possible to customize the Log file names using any of the credentials used in logging on, or some other customization--in the following sample, the active "Userid" logon field value is being used for the log file instead of "Users". The name of the application / web service project can also be used:
void DebugFactory(IOBag ioBag)
{
System.DateTime dt=System.DateTime.Now;
Dbg=new Debug(null,String.Format("{0}_{1}_{2,-14:HH:mm:ss:fff}",
ioBag[FieldID.Userid],dt.ToShortDateString(),dt));
this.oConn.owner = Dbg.LogFileName;
}
The logging functionality in the FVTerm internal services will utilize the active session's HostConnection object "owner" property as the name of the log file. As such, it is imperative that this value be set during initialization of the web service's session in order to have unique log file names (otherwise, all FVTerm logging will go to the ".NET.log" file). This is achieved in the above example with the line:
this.oConn.owner = Dbg.LogFileName;