Methyl formate, HCOOCH3, is a well-known interstellar molecule prominent in the spectra of hot molecular cores. The current view of its formation is that it occurs in the gas phase from precursor methanol, which is synthesized on the surfaces of grain mantles during a previous colder era and evaporates while temperatures increase during the process of high-mass star formation. The specific reaction sequence thought to form methyl formate, the ion-molecule reaction between protonated methanol and formaldehyde followed by dissociative recombination of the protonated ion [HCO(H)OCH3]+, has not been studied in detail in the laboratory. We present here the results of both a quantum chemical study of the ion-molecule reaction between [CH3OH2]+ and H2CO as well as new experimental work on the system. In addition, we report theoretical and experimental studies for a variety of other possible gas-phase reactions leading to ion precursors of methyl formate. The studied chemical processes leading to methyl formate are included in a chemical model of hot cores. Our results show that none of these gas-phase processes produces enough methyl formate to explain its observed abundance.