[1] At the start of the war in 1808, as captain of one of two companies of Sappers, garrisoned at Guadalajara, Veguer played an active role in an episode known as the La fuga de los Zapadores ['The Flight of the Sappers'], in which many of the units of the Spain's Royal Regiment of Sappers Engineers, deployed around the country, together with some of the teachers and students at the military academy at Alcalá de Henares, decided to march to Valencia to fight against the French invaders,[1] thereby becoming the first Spanish military unit as such, as opposed to individual desertions, to defy the confinement to barracks imposed on Spain's army by the Captain General of Castile, Francisco Javier Negrete, following the Dos de Mayo Uprising in Madrid.
[2] Leaving on 24 May, with colours flying, they reached Valencia on 7 June, where they reformed under Veguer,[3] and adding two new companies of soldiers with different trades, such as carpenters, stonemasons, etc.
with which Verguer formed the Valencian Regiment of Sappers, ceding his command to the superiority of the Count of Cervellón who, on 23 May, had made a call to arms against the French.
[1] In 1810, Veguer, then second-in-command of the Castle of La Suda, was one of the six Spanish generals taken prisoner at the siege of Lérida (29 April – 13 May 1810), when an Imperial French army under Louis Gabriel Suchet besieged Llieda.
[4] Following his release, he was last known to have been in Sevilla in July 1814, when he published his Apuntes sobre el modo de establecer un ejército permanente [Notes on How to Establish a Permanent Army], several points from which, including aspects such as recruit training centres and regimental schools, were still being applied over two hundred years later.