How to activate tracing in ERPConnect
For debugging, you can activate the tracing feature of ERPConnect by setting the Logging = true and the and the Logdir to an existing directory before calling the Open() method (or before Start() if you are using an RFCServer Object).
There are 4 different variations how to set the properties:
1). Logging = false and LogDir = non-existing-path:
Tracing is disabled. No files are generated. (Default)
2). Logging = true and LogDir = non-existing-path:
same as 1)
3). Logging = false und LogDir = existing-path
Tracing is activated, files are generated in the directory specified by LogDir. Only RFC errors are traced.
4). Logging = true und LogDir = existierendes-Verzeichnis
Tracing is activated, files are generated in the directory specified by LogDir. Full RFC traces are generated.
using (R3Connection r3connection = new R3Connection("SAPServer", 00, "SAPUser", "Password", "EN", "800")){ r3connection.LogDir = @"C:\Temp\Trace"; // (directory must exist) r3connection.Logging = true; r3connection.Open(); // do stuff with r3connection}