No need to switch during live performance.
Switch off Local Control at the start of the gig (keep it off) and when you need to access internal sounds, switch to a rackspace where you have a MIDI In block connected to the MIDI Out block for your hardware keyboard. It’s the equivalent of Local Control being set to on.