The regiment remained in Ireland until the early part of 1719, when the preparations made by the King of Spain to forward the interests of the Pretender, occasioned it to be withdrawn from that country; and it was subsequently encamped in the Isle of Wight, and held in readiness for active service. The British Government projected the capture of Corunna, in Biscay, and of Peru, in South America; and the Thirty-fourth sailed in the early part of September with the expedition, under General Viscount Cobham, for the attack of the former place; but on arriving off the coast of Gallicia, circumstances occurred which occasioned an attack on Vigo to be resolved upon. The fleet entered the harbour of Vigo on the 29th of September, seized on seven Spanish ships, and on the following day the troops landed under the fire of musketry from the mountains. Advancing towards the town, the British forced the Spaniards to abandon Vigo and Fort St. Sebastian, which were taken possession of by eight hundred men, under Brigadier-General Honeywood. A battery being opened against the citadel, the garrison was soon induced to surrender, giving up two thousand barrels of powder, eight thousand muskets, and fifteen pieces of brass artillery, which had been prepared for the invasion of Britain in favour of the Pretender. While the siege of the castle of Vigo was in progress, Rondondella was captured by a detachment from the army; and on the 12th of October a thousand men proceeded, under Major-General Wade, against Pont-a-Vedra, from whence thirteen companies of Spaniards fled in a panic; the town, arsenal, barracks for two thousand men, thirteen pieces of brass and eighty-six of iron ordnance, five thousand small arms, three hundred barrels of powder, and a great quantity of other stores, were captured. The arsenal, barracks, and Fort Marine, were destroyed; the iron ordnance and the more valuable stores were removed on board the fleet.
Finding himself oppressed on every side, and his resources exhausted, the King of Spain made pacific overtures; and a treaty of peace was concluded before the expedition to Peru was undertaken. The armament returned to England, and the Thirty-fourth were again stationed in Ireland.
1723
On the 18th of February, 1723, Lieutenant-Colonel Robert Hayes, from the command of a company in the First Foot Guards, was appointed colonel of the regiment, by purchase, in succession to Colonel Chudleigh, who retired.
1726
Few years elapsed before the Spanish monarch again violated the peace of Europe. The possessions, of which he was deprived by the peace of Utrecht, in 1713, had been relinquished with reluctance, and towards the end of 1726, he assembled an army in Andalusia, under the command of the Count de la Torres, to make a determined effort for the re-capture of Gibraltar.
1727
In February, 1727, the garrison of Gibraltar opened its fire on the besieging army; and the Thirty-fourth Regiment was, at this period, on its way from Ireland, to share in the honor of a successful defence of this important fortress. The regiment encountered a storm at sea, and lost several companies by shipwreck; six companies proceeded to Plymouth, and afterwards continuing their voyage, arrived at Gibraltar on the 26th of March, in company with the Twenty-fifth Regiment; they were followed by several other corps. The garrison made a very gallant defence of the fortress committed to their charge, against the storm of war, which raged against them with increasing fury until the thunder of one hundred cannon became almost incessant in the day time, and was partially continued throughout the night. The tremendous fire of the Spaniards produced little effect beyond the bursting of many of their own cannon, and rendering others useless; and many thousands of the besieging army perished in the attempt. In the early part of June, the fire slackened; on the 18th of that month hostilities ceased; and the fortress of Gibraltar continued to form one of the trophies of British prowess.
1728
Peace having been concluded with Spain, the regiment was withdrawn from Gibraltar, and proceeded to Ireland, where it was conspicuous for its good conduct in quarters.