Hello,
I have the following code for using the trace:
Code:
public sub New()
'The DatabaseTraceListener is a class that I created
Trace.Listeners.Add(new DatabaseTraceListener())
end sub
protected overrides sub Finalize()
mybase.Finalize()
Trace.Listeners.Clear()
end sub
I use this in my code in multiple classes. Whenever the class is created, a trace is created and upon finalization, the trace is removed. However, if I have multiple classes open, and one finalizes and calls the clear() method, will that remove the trace listener for the other class? If so, how would I only remove the appropriate trace object for the class, other than maintaining a global variable trace object?
Thanks,
Brian Mains