Despite the setback, Venegas was given command of the "Army of La Mancha" after its previous commander was badly beaten at the Battle of Ciudad-Real on 27 March 1809. In mid-July 1809 Venegas and his 23,000 soldiers sparred with the French IV Corps, carefully avoiding being drawn into battle with 20,000 troops of superior quality. According to the strategic plan, Venegas was supposed to ensure that the IV Corps did not combine with other French forces against Arthur Wellesley's British and Gregorio García de la Cuesta's Spanish armies. However, the IV Corps managed to elude Venegas and join the army of Joseph Bonaparte for the Battle of Talavera on 27–28 July. The action resulted in an Anglo-Spanish victory. With only a handful of enemies in front of him, Venegas had a brief chance to recapture Madrid, but he allowed the opportunity to slip away. At the head of an army of 20,000 foot and 3,000 horse, Venegas ignored Cuesta's orders to retreat and stood to fight on 11 August 1809. Venegas believed that he faced only 14,000 Frenchmen, but in fact Joseph's army consisted of 17,000 infantry and 4,000 cavalry. In the Battle of Almonacid the Spanish army was defeated with the loss of 800 killed, 2,500 wounded, 2,000 prisoners, and 21 cannons. French casualties numbered 319 killed and 2,075 wounded, indicating that the Spanish troops fought well. A few weeks later, Venegas was replaced in command by Juan Carlos de Aréizaga.