problem with listdir

jimgardener jimgardener at gmail.com
Sat Apr 26 03:24:23 EDT 2008


hi
i have a directory containing .pgm files of P5 type.i wanted to read
the pixel values of these files ,so as a firststep i wrote code to
make a  list  of filenames using listdir

pgmdir="f:\code\python\pgmgallery" # where i have pgm files
g2=listdir(pgmdir)

i get the following error
WindowsError: [Error 123] The filename, directory name, or volume
label syntax is incorrect: 'f:\\code\\python\pgmgallery/*.*'

i am running python on winXP ..can anyone tell me why i get this
error?



More information about the Python-list mailing list