It's because the pupil suddenly shrinks therefore triggering nerves which are somehow conected to the sneezing process. I do it all the time. That's Trev Santos for ye though