The transit of Venus can't be observed with the Hubble Space Telescope because the extreme brightness of the sun would destroy the telescope and its instruments.
Opportunities to photograph Mercury from space are also limited because light sensitive equipment, such as the Hubble Space Telescope, are not allowed to look at objects close to the Sun, such as Mercury or Venus.