The PhotoGallery tends to get installed with HP software, particularly with HP printers.. The next time you see the error, place the HP printer installation disc in your disc drive, then direct the browse feature to the disc drive. It should find the file it's looking for.
See the discussion below which offered a similar fix:
http://www.windowsbbs.com/other-pc-software/51983-error-please-wait-while-windows-configures-photogallery.html
Hope this helps.
Grif
Every time I turn my desk top on, it says' Window is configuring photoGallery. " What is causing this to happened?

Chowhound
Comic Vine
GameFAQs
GameSpot
Giant Bomb
TechRepublic