Gasparinetti had inexplicably left the University of Padua in 1796 shortly before taking his final examinations and returned to his family's home in Ponte di Piave. The following year, he enlisted in the "Armée d'Itali"e. Over six feet tall and skilled in both firearms and horseback riding, he was given the rank of lieutenant in the newly formed light cavalry regiment ("Chasseurs à Cheval"). He distinguished himself in the Battle of Genola and the Siege of Genoa where both he and Foscolo were wounded and rose to the rank of captain. His military service was interspersed with periods of leave during which he dedicated himself to his literary pursuits. After one such period in 1809, he planned to retire permanently from the army, but his regiment was called up for the War of the Fifth Coalition. Gasparinetti participated in several battles of that campaign, most notably the Battle of Wagram where he was wounded and taken prisoner by the Austrians. On his release, he was awarded the Legion of Honor by Napoleon.