An X-ray imaging apparatus including an X-ray generation means for emitting X-rays,
and an X-ray detector on which a grid selected from a plurality of different types
of grids is removably mountable. The X-ray detector receives the X-rays emitted
from the X-ray generation means, and obtains an X-ray image. The X-ray detector
includes an automatic exposure control (AEC) detector for detecting the quantity
of X-rays emitted from the X-ray generation means and for outputting a signal based
on the detected quantity. The X-ray imaging apparatus also includes a control means
for controlling the X-ray generation means and the AEC detector, where the control
means controls the X-ray generation means based on the signal output from the AEC
detector, and where the control means controls the AEC detector using correction
data to correct an exposure detection element forming a part of the AEC detector.