An inspecting apparatus for inspecting a substrate includes an objective
lens attaching part equipped with a plurality of objective lenses each
having a different working distance (WD), an objective lens exchanging
device which exchanges the objective lens, and a loading stage which is
opposed to the objective lens and on which the substrate S is loaded. An
objective lens detecting device detects the WD of the objective lens.
Displacing devices relatively displace the objective lens and the loading
stage in the direction of the optical axis of an inspecting light path
and a direction rectangular to the optical axis. And a displacement
controlling device controls the relative displacement of the objective
lens and the loading stage in the direction rectangular to the optical
axis when the lens detecting device detects that the WD of the objective
lens is shorter than a predetermined WD.