Using a scanning tunneling microscope for point contact measurements, we obtained laterally resolved information of the magnetoresistive properties of nanostructured spin-valve elements. A good correlation is found between magnetization and magnetoresistance curves of single-domain elliptical elements (450nm by 150nm), for magnetic fields applied along their long and short axes. In ring-shaped elements (inner and outer diameters 1.8 and 2.2μm), different magnetoresistance curves are acquired as different points around the ring are probed. The observed switching can be related to the onion state of the rings, and it clearly demonstrates a lateral resolution ⩽100nm.