Experiments on the combination of the high power wave beams from two gyrotrons and fast switching of the combined beam between two transmission channels are described. The measurements were performed using a high-power resonator diplexer in the optical transmission line of the electron cyclotron heating system for W7-X. The principle and the engineering design of the prototype fourport quasi-optical diplexer is presented. The wave beams from two gyrotrons with an output power of 370 kW and 560 kW, respectively, have been combined for pulse lengths up to 10 seconds, only limited by the un-cooled mirrors used in the diplexer. By modulating the gyrotron frequency using a fast high-voltage body modulator, controlled toggling of the combined power between the two outputs of the diplexer was demonstrated with switching frequencies of up to 20 kHz.The experiments are compared to theory, showing good agreement when the limited stability of the free-running gyrotrons is taken into account.