Hi,
This behavior will occur if the form factor for your laptop is set up as if it is a tablet.
If you have a laptop with a permanently-attached keyboard and where autorotation isn’t available, try running this automated Keyboard Troubleshooter. This troubleshooter toggles the registry keys that affect this (on-screen) touch keyboard and auto-rotation behavior. Run the troubleshooter once to set your PC as a laptop and disable these tablet features. You can run the troubleshooter again to turn the touch keyboard and autorotation back on, as if it is a tablet.
We do NOT recommend stopping the touchscreen service to alleviate this issue, because other features depend on that service to function properly.