I have a method which returns System.Timers.Timer and then I use it along the code.
But MS Code Analysis gives a warning: CA2000: Dispose objects before losing scope
Is it possible to manually Dispose Timer and therefore not to spot such a message?
Thank you!
Since
System.Timers.TimerimplimentsIDisposableyou can wrap your method call in ausingstatement to make sureDisposeis called.