我需要一个适合我的 Visual Basic 中的等待命令。
我知道:
Declare Sub Sleep Lib "kernel32.dll" (ByVal milliseconds As Long)
sleep 5000
但这会使程序无响应。
System.Threading.Thread.Sleep(5000) 'The window doesn't load until the timing is over (useless)
我的代码:
Imports Microsoft.Win32 'To check if is 64Bit or 32Bit
Public Class Loading
Private Sub Loading_Load(sender As Object, e As EventArgs) Handles MyBase.Load
If Registry.LocalMachine.OpenSubKey("Hardware\Description\System\CentralProcessor\0").GetValue("Identifier").ToString.Contains("x86") Then
My.Settings.Is64 = False
Else
My.Settings.Is64 = True
End If
'I need command here
If My.Settings.Is64 = True Then
Form64.Show()
Me.Close()
Else
MsgBox("No version developed for 32-bit computers.")
End
End If
End Sub
End Class
错误:
@Idle_Mind
1. function 'OnInitialize' cannot be declared 'Overrides' because it does not override a function in a base class.
2. 'MinimumSplashScreenDisplayTime' is not a member of 'App.Loading.MyApplication'.
3. 'OnInitialize' is not a member of 'Object'.