Public Class Form1
Declare Function Wow64DisableWow64FsRedirection Lib "kernel32" (ByRef oldvalue As Long) As Boolean
Declare Function Wow64EnableWow64FsRedirection Lib "kernel32" (ByRef oldvalue As Long) As Boolean
Private osk As String = "C:\Windows\System32\osk.exe"
Private Sub Form1_Load(sender As System.Object, e As System.EventArgs) Handles MyBase.Load
Dim old As Long
If Environment.Is64BitOperatingSystem Then
If Wow64DisableWow64FsRedirection(old) Then
Process.Start(osk)
Wow64EnableWow64FsRedirection(old)
End If
Else
Process.Start(osk)
End If
End Sub
End Class