Seems like you are not providing a full path to the file 'check.jpg'.
How is your program supposed to know where in the filesystem it
is located? Either that, or you have to put the file in the same
directory that on which the program is running.
Also, you should use two backslashes in the name: part
body = part.startbody('image/jpeg; name=c:\\check.jpg')
This is because \ is the escape character in strings. If you
mean a literal backslash, it has to escape itself. Hence,
you use \\
Hope that helps!
-Luis
--
http://mail.python.org/mailman/listinfo/python-list