Well I dont know the exact argument used by Dirac, but by assuming quantization of angular momentum and the existence of a magnetic monopole it is possible to show that electric charge must be quantized

The essential argument is as follows. Consider a magnetic monopole and an electric charge. We know that the resultant crossed electric and magnetic fields have a linear momentum
p =epsilon0 * (E x B) and
and an angular momentum L = r x p

It turns out that the total angular momentum is proportional to the product of q(the magnitude of the charge) and g(the magnitude of the magnetic monopole). As we know that angular momentum comes in bundles of h/(2*pi) we can conclude that q must be quantized(If the product of q and g is quantized then q must be quantized).