There is no way to control an earthquake, we cannot predict them until they are about to happen.
What we can do is to build edifications prepared to dissipate all the energy from the seismic movements. The buildings should be "elastic" or "fluid" structures in order to give time to people to get out the edification, because if we build them too rigid they can be too expensive or they could suddenly fall off.