This could be a math question. But if you think about the physical aspect of the question, it is interesting to look at the Schrodinger equation:
For free fields (without potential), you have (in units $\bar h = m = \omega = 1$):
$$i\frac{\partial \Psi( k, t)}{\partial t} = \frac{ k^2}{2}\Psi( k, t)$$ or
$$ E \tilde \Psi( k, E) = \frac{ k^2}{2} \tilde \Psi( k, E)$$
Whose solution is :
$$\Psi( k, t) \sim e^{- i \frac{ k^2}{2} t}$$
or
$$ \tilde \Psi( k, E) \sim \delta \left(E - \frac{ k^2}{2}\right)$$
Here $ \tilde \Psi( k, E)$ is a Fourier transform of $\Psi( k, t)$.
It is clear, from the form of the equations, that there is no constraint about $E$. It is a continuous spectra, and this is clearly a non-normalizable solution.
However, with potentials, things appear differently, and you will have some differential equations, for instance, for the harmonic oscillator potential, you will have :
$$ E \Psi( k, E) = \frac{ k^2}{2} \Psi( k, E) - \frac{1}{2}\frac{\partial^2 \Psi( k, E)}{\partial k^2}$$
The solution for $\Psi$ involves a Hermite differential equation (multiply by some exponential $e^{-k^2}$).
If E is taking continuous, then the Hermite solution (with a real index) is not bounded at infinity, and so the solution is not normalizable.
If we want a normalizable solution, then we need a (positive) integer indexed solution $H_n$, whose name is Hermite polynomials. In this case, the spectrum of $E$ is discrete.
The choice of $E$ discrete (and so a normalizable solution) is then a physical choice. In the case of the harmonic oscillator, it is unphysical to suppose that the solution is not bounded at infinity.
The case of Hermite polynomials is a special case of orthogonal polynomials, which is very well suited to represent orthonormal states, corresponding to discrete eigenvalues of the hermitian operator Energy.