Hi,BUT! How long before the 9V battery is drained? I did something similar for a freezer door alarm and discovered that for some reason beyond my skill or understanding level lasted for only two weeks. My concern is for the longevity of the battery - and no - please don't make a separate thread for my question. I'M NOT ASKING - I'M POINTING OUT! Some moderators have taken my questioning as hijacking. I'm only pointing out that using a 9V battery with a 1megΩ resistor will still drain. And at some point it's going to be too weak to react with an alarm.
The super-cap seems like a good idea, but as you pointed out - expense may be an issue. Another issue would be audibility of the buzzer (I didn't see one defined by the TS, maybe I missed that). What kind of power is it going to draw?
I did a refrigerator door monitor a long time ago and got 2 years out of the AA batteries.
The trick is to have it show the status just once every so often, like 10 minutes, and if there is a fault, have it show up more often but not continuous. IF it shows up once per minute it will make the battery last 60 times longer than if it runs continuously.
I used a microcontroller which had a 'sleep' function. During sleep, the uC chip consumes extremely low power and thus low current from the batteries. Maybe 10na cant remember, but to the batteries it's almost nothing.
Using a bright LED to show the status also means consuming less power during the time it has to be shown. The LED can be pulsed with a very short pulse and still be visible, which overall means very low power consumed. For a buzzer, just turn it on for a short time just like how a fire detector works when the battery runs down, and also have a different buzz pulse pattern for when the battery gets low.
The thing about a refrigerator is if the temperature gets above a certain point then another 5 minutes wont make that much difference so the check can be once every 5 minutes or something like that, along with the LED status indication.
I used a multicolor super bright LED. Green for good, red for temperature too high, something like that. I dont use it anymore i use a mechanical method to make sure the door is shut.