Qiangning Hong <[EMAIL PROTECTED]> wrote: >I want one of my function to execute when a cdrom is inserted. How can I >achieve that? > > Further more, I want to do different things depend on the inserted disc type: > if it is a normal > cd-rom, read from it; if it is a recordable cd, write data on it. So, how > can I get the inserted > disc type infomation in Python code?
1) figure out how notifications work. typing your subject line into a google search box and clicking "I feel lucky" brings up this page: http://support.microsoft.com/default.aspx?scid=kb;en-us;163503 2) figure out how to handle an WM_DEVICECHANGE event in the UI framework you're using; this is a framework issue, not a Python issue (Python doesn't process Windows events by itself). 3) check the "REFERENCES" section on the above page for more details. hope this helps! </F> -- http://mail.python.org/mailman/listinfo/python-list