How did edward Jenner discover the smallpox vaccine?

Incorrect assumption in your question:

Edward Jenner did not discover the smallpox vaccine. He is credited with discovering the vaccine (specifically for smallpox) through inoculation with cowpox.

Viruses - Related Articles