Running calc.exe on windows server 2019

FYI Windows Server 2019 / Xojo 21r3.1

How can I execute calc.exe on windows from a button press?

I’ve tried using a shell object dragged onto the window
I’ve tried declaring a shell as a property
I’ve tried s.execute “calc.exe”
I’ve tried s.execute “cmd.exe /c calc.exe”
I’ve tried s.execute “C:\Windows\System32\calc.exe”
I’ve tried different ExecuteModes
DataAvailable Never Fires

I can type any of these commands into the command prompt without issue.

I also can’t get it to work in VB6 using shell. Strange…

What am I missing?

What about:

Var  fh as FolderItem
fh = new FolderItem ("C:\Windows\System32\calc.exe", FolderItem.PathModes.Native)
fh.Open

Didn’t work on my end.

This works for me on Windows 10, using a local shell variable.

Dim sh As New Shell 
sh.Execute ("C:\Windows\System32\calc.exe")

That local shell works for me too! Thanks! Why it doesn’t work on a shell window property or one dragged onto a window is a little concerning!

Dim calc As FolderItem = SpecialFolder.System.Child("calc.exe")
calc.Open()