Since you said touchpad, I assume it's a laptop. Why are you touching the touchpad while typing? Perhaps you should just learn to type properly, since unless it's a REALLY weird layout on your laptop model, any even-remotely correct form of typing should never have you touching there, I mean, laptops are designed most of the time with such problems in mind...
But anyway, just disable the touchpad if it's really that problematic to you, then even if the mouse were to not work (eg: no battery or whatever), if it's a Windows system it can be controlled 100% using just the keyboard. Using Alt commands, Tab, Windows and since it's a laptop even Fn should be more than enough to have full use of it without ever needing the mouse, meaning you can still re-enable the touchpad when you need it