Refs #8343 Fixed error and refactored code.

Also modified the interface code to only allow the user to input a valid
min/max value.
Merge branch 'bugfix/8343_c2e_diag_tab_spectrum_error' into develop