System.AppDomain.GetCurrentThreadId C# (CSharp) Method