/
aprogrammer
/
dotnet-docs
Обзор
Документация
Войти
/
aprogrammer
/
dotnet-docs
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
docs/fundamentals/runtime-libraries/snippets/System/DateTime/Overview/vb/Resolution.vb
50 строк
1 KB
Genevieve Warren
Add remarks for core types (#38970)
05 янв 2024, 22:14
Не верифицирован
05 янв 2024, 22:14
71d1377
Код
Авторство
О чём код?
Imports System.Threading Module Resolution Public Sub Snippets() DemonstrateResolution() End Sub Private Sub DemonstrateResolution() ' <Snippet1> Dim output As String = "" For ctr As Integer = 0 To 20 output += Date.Now.Millisecond.ToString() + vbCrLf ' Introduce a delay loop. For delay As Integer = 0 To 1000 Next If ctr = 10 Then output += "Thread.Sleep called..." + vbCrLf Thread.Sleep(5) End If Next Console.WriteLine(output) ' The example displays output like the following: ' 111 ' 111 ' 111 ' 111 ' 111 ' 111 ' 111 ' 111 ' 111 ' 111 ' 111 ' Thread.Sleep called... ' 143 ' 143 ' 143 ' 143 ' 143 ' 143 ' 143 ' 143 ' 143 ' 143 ' </Snippet1> End Sub End Module