His wife and his mother both died in rapid succession, and he escaped to a cattle ranch in the Dakotas. He served as Assistant Secretary of the Navy under President William McKinley, but he resigned from that post to lead the Rough Riders during the Spanish–American War, returning a war hero. He was elected governor of New York in 1898. After Vice President Garret Hobart died in 1899, the New York state party leadership convinced McKinley to accept Roosevelt as his running mate in the 1900 election. Roosevelt campaigned vigorously, and the McKinley–Roosevelt ticket won a landslide victory based on a platform of peace, prosperity, and conservation.