It's also why telescopes work at night. The sun is very bright and overwhelms the faint light from stars which is why stars aren't visible on a sunny afternoon.
When the lunar landings were taking place it was daytime on the Moon. So the same overpowering effect of sunlight still took place. Indeed, it was even worse than on Earth since the Moon has no atmosphere to diffuse and scatter the sunlight.
It seems some folks see the black sky in lunar photos and think nighttime since that's how it works on Earth. But the lunar sky is black regardless of whether it is daytime or nighttime.
I just want to correct a few things. Seeing the stars, and photographing them are two different things. If Earth didn't have an atmosphere, we'd be able to see the stars during the day, sun or no sun, the thing that stops us is that the sunlight, manily the longer blue wavelengths, is scattered causing the sky to become bright and blue, thus blocking out the stars, though if you have the right equipment, and know where to look, you can see stars during the day. Venus (and of course the Moon) are also visible during the day withthe naked eye, if you know where to look. On the moon, without the atmosphere scattering the light, you can easily see the stars, if you allow your eyes to adjust from the bright lunar surface, and in fact several Astronauts did state that if they got themselves into shadow and waited a few minutes they started to see the stars.
Now a photo is a totally different animal, it has set exposure settings, and those where predominately set for sunlit lunar surfaces. When set for shadowed areas the settings were enough that in theory Venus would be bright enough to affect the exposure and appear, Sirus is a maybe. To date I don't think anyone has been able to so that Sirus appears in any images, but....
If you look at
this series of nine images.... Venus has been found, nearly 40 years after the landings, and due to a Hoax Believer (yeah they are useful for something) who worked out that it should have been in the Apollo 14 images. A bit of a hunt later and one of out ApolloHoax regulars found that indeed it was there.