我需要一种方法来从WebService(服务器端)获取完成功能或过程所花费的时间,是否有任何简单的方法来做到这一点?
我正在使用VB.net和Visual Studio 2017
答案 0 :(得分:0)
soohoonigan说了什么
Private Function SomeFunction() As Boolean
Dim stpw As Stopwatch = Stopwatch.StartNew 'start timing
'
'
'
'
'and then
stpw.Stop() 'stop timing
'
' the stpw.Elapsed property is a timespan
Return False
End Function