The codes show that by using the QueryPerformanceCounter, to implement hight performance/resolution timer and counter. I have tried the from WinForm UI and CLI. The resolution can be 1ms. Of course, this will satisfy us for our normal using.
The code is blow. Enjoy it.