A multilayer microcircuit on a diamond surface has been developed for high-pressure resistivity measurement in a diamond anvil cell (DAC). Using a film deposition technique, a layer of Mo film was deposited on a diamond anvil as a conductor, topped with a layer of alumina film for insulation. A microelectric circuit was fabricated with a photolithographic shaping method after film encapsulation. With precise control and measurements of all the dimensions of the sample for resistance measurement, including the width of the metallic film and the diameter and thickness of the gasket hole, resistivity of a sample can be accurately determined. This microcircuit can be flexibly fabricated and easily cleaned. It also provides a promising prospect to measure resistivity under in situ high pressure and high temperature. We measured the resistivity of ZnS using this method, and proved the pressure induced phase transition at 13.9-17.9 GPa to be a semiconductor to semiconductor transformation.