War of the Spanish Succession
During the War of the Spanish Succession, 1702–1713, he was director of the "capilla real."