On Nov 15, 10:21 am, Tim Golden <[EMAIL PROTECTED]> wrote: > Gabor Urban wrote: > > OK, you are right... Problem was not precise enough. I need to process CDs > > to create a list. Does it ring a bell for you? > > On Windows, at least, you can do this with WMI: > > <code> > import win32com.client > > wmi = win32com.client.GetObject ("winmgmts:") > for result in wmi.ExecQuery ( > """SELECT VolumeSerialNumber > FROM Win32_LogicalDisk > WHERE DriveType=5""" > ): > print result.Properties_ ("VolumeSerialNumber") > > </code> > > If you do anything non-trivial with WMI, I <cough> recommend > my WMI module: > > http://timgolden.me.uk/python/wmi.html > > TJG
I recommend Tim's module too. Using the win32 module's directly is usually much more complicated. Mike -- http://mail.python.org/mailman/listinfo/python-list