On Mon, May 5, 2008 at 10:09 AM, globalrev <[EMAIL PROTECTED]> wrote:
> On 5 Maj, 14:17, "Wojciech Walczak" <[EMAIL PROTECTED]>
>  wrote:
>  > 2008/5/5, globalrev <[EMAIL PROTECTED]>:
>
> >
>  > > 
> pygame.mixer.music.load('C:/Python25/myPrograms/pygameProgs/example1.mp3')
>  >
>
> > Are you sure that:
>  >
>  > os.path.exists('C:/Python25/myPrograms/pygameProgs/example1.mp3') == True?
>  >
>  > Check it with python.
>  >
>  > --
>  > Regards,
>  > Wojtek Walczakhttp://www.stud.umk.pl/~wojtekwa/
>
>
>  >>> import os
>  >>> os.path.exists('C:/Python25/myPrograms/pygameProgs/dront.mp3') == True
>  False
>
>
>  but...it is there....
>
>  >>> os.path.exists('C:\Python25\myPrograms\pygameProgs\dront.mp3') == True
>  False

What about:

os.path.exists('C:\\Python25\\myPrograms\\pygameProgs\\dront.mp3') == True

That's what Diez mentioned earlier in the thread about escaping the slashes.
>
>  does it matter if i use / or \? which si recommended?


Which slash to use basically depends on whether you're on Windows
(uses \ as a path separator) or *nix (uses / as a path separator).
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to