latex class: Replace integer test for questionnaire ID

The old IsInteger test would always return false. This is
now replaced with another test from the same source which
works fine.