How to deactivate the mouse when a gamepad is being used?

Hi, I’ve been working on navigating UI menus with a gamepad (Xbox controller). In my start menu, before the game begins, I want to hide the mouse and disable any hover-over events. The thing is I set an On Key Down to check if a gamepad key is being pressed. The if true, Set Show Mouse Cursor to false. But the mouse is still shown on screen like normal. Any suggestions on how to remedy this?

Did you find a solution to the problem yet?
if you can update if you found a solution, I’d really appreciate it, I’m currently facing the same problem