McKnight served later as a surgeon in the Pennsylvania Battalion of the Flying Camp. On April 11, 1777, he was appointed Surgeon General (also called Senior Surgeon, a subordinate position to Physician General and Director General, not to be confused with Surgeon General of the United States Army) of the Flying Hospital of the Middle Department, which moved with the army during the New York and New Jersey campaign. He served as Senior Surgeon for three years. In December 1779, McKnight was in Morristown, New Jersey with Washington, at the encampment near Jockey Hollow, during the worst winter of the Revolutionary War.