So, I have a Canon EOS 500n, I do not know much about photography and I didn't find this problem on the internet, so here it goes. Everything worked fine, but then, some time ago, the flash stopped working. What happens is when the camera pops up the flash, i makes a weird clicking noise and the no-battery icons flashes on the display. I already tried different batteries, new and used, and it makes no difference. I never dropped the camera, I always handled it with care so this started happening out of nowhere. When trying to take an automatic shot, and it tries to use the flash, this happens. And also when trying to use the flash manually. What could this be? A problem with the flash itself or an electronic problem with the whole camera? Everything else works fine. Thanks for the help!
"Weird clicking noise" sounds like a flash capacitor breakthrough. The exact sound would be the typical charge whine (assuming it is audible at all) going up but then with a hard popping noise jumping lower in pitch again repeatedly, never reaching the voltage necessary for triggering the flash.
That's a single circuit element that may or may not easy to get a replacement for (and then somebody still needs to swap it): not because it is complex or unusual to produce but because it is bulky with sort of an arbitrary cylindrical shape, and the replacement will have to have pretty much the same size and shape to fit in the camera. Though an old EOS might be somewhat less cramped for space than modern smaller cameras.
Don't continue using the flash: continuous breakthroughs will cause corrosive liquid to evaporate in the capacitor and it might bulge and damage things mechanically or by leaking. Earlier capacitors also could outright explode but I think that these days probably the enclosure is designed to avoid that specific failure mode.
Maybe consider using an external flash.