I would like to trace HTTP communication in my c# assembly (.Net 4.5). As the .Net code is wrapped with COM interop and finally used in COM container applications I have no app.config file of the main app to configure tracing the usual way.
What I have found so far was always at some point tied to app.config (e.g. rewrite that file and load with ConfigurationMagager or Trace.refresh())
There is an SO answer about enabling tracing at runtime without an app.config file using reflection. Is this the only route or is there a simpler way to switch on tracing, say, for the DEBUG version of such an assembly?