I see the following in the Explorer:
Now I try to run it using
Shell "C:\Windows\System32\osk.exe", vbNormalFocus
It fails, saying "File not found".
I am confused.
I call:
Shell "C:\Windows\SysWOW64\osk.exe", vbNormalFocus
The same error occurs.
When I use the following function to check for the existance, it also returns False.
Public Function FileExists(ByVal uPath As String) As Boolean
Const NotFile = vbDirectory Or vbVolume
On Error Resume Next
FileExists = (GetAttr(uPath) And NotFile) = 0
On Error GoTo -1
End Function
I am really baffled what might be going on here.

Windows has a feature for 32 bit programs only. To 32 bit programs
C:\Windows\SysWOW64\osk.exeis exactly the same file asC:\Windows\System32\osk.exe(but not to 64 bit) and both refer toC:\Windows\SysWOW64\osk.exe.So for a 32 bit program to access
System32it needs to use a special name -C:\Windows\SysNative\osk.exe. Note the file redirector will look after it - there is no folder of that name.Using that path on a 64 bit program will cause an error. Only 32 bit programs need it and only they can use it.