In 1861 he was admitted to the bar in
Peekskill, New York, and in
Wilkes-Barre, Pennsylvania, in 1861. He served as prothonotary's clerk in 1861, and served in the pay department of the
Union Army at
New Orleans in 1862 and 1863. He was a member of the constitutional convention of Pennsylvania in 1872 and 1873, and served as attorney general of the State in 1879 through 1883. Palmer was elected as a Republican to the
Fifty-seventh,
Fifty-eighth, and
Fifty-ninth Congresses. He was one of the managers appointed by the
United States House of Representatives in 1905 to conduct the impeachment proceedings against
Charles Swayne, judge of the United States Court for the Northern District of
Florida. He was again elected to the
Sixty-first Congress. He practiced law until his death in Wilkes-Barre on February 15, 1913. He was interred in Hollenback Cemetery. ==Family==