Is there anything wrong with using lock with a try block? I remember reading somewhere that we should always try to put minimum amount of code within try block and lock itself i
you can always use the longer syntax like this:
System.Threading.Monitor.Enter(x); try { ... } catch(Exception e) { } finally { System.Threading.Monitor.Exit(x); }