In 1872 Gresham was elected district attorney for Galveston and Brazoria counties. He was a stockholder, director, and attorney for the Gulf, Colorado and Santa Fe Railway and served for a time as its second vice president. In the infancy of the railroad he was much in the field, selecting routes, securing rights-of-way, locating towns, and superintending other business. In 1887 and 1888 he represented Galveston at conventions in Fort Worth, Texas; Denver, Colorado; and Topeka, Kansas. At Topeka he was made chairman of a special committee to petition the United States government to finance a deepwater harbor at the best point on the Texas coast. He was instrumental in having the Fifty-first Congress amend the River and Harbor Bill to provide for contracts for work to give Galveston one of the finest harbors on the American coast.
Gresham's home, known now as the Bishop's Palace for the Catholic bishops who later resided there, was designed by architect Nicholas J. Clayton. Gresham represented the Sixty-fourth District in the Texas House of Representatives from 1887 to 1891. He was elected on the Democratic ticket from the Tenth District to the Fifty-third Congress in 1892 but was unsuccessful in the race for reelection. In 1901 he served as president of the Trans-Mississippi Commercial Congress. On October 28, 1868, Gresham married Josephine C. Mann, with whom he had nine children. He died in Washington, D.C., on November 6, 1920, and was buried in Lakeview Cemetery, Galveston.
29° 16.353, -094° 49.502