View Single Post
Old 03-03-2008, 05:50 PM   #1
xixix
Junior Member
xixix began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Mar 2008
Device: PRS-505
rtf2lrf shows IOError: [Errno 2] if special characters in filename

Dear All,
tried to search forums but no trace of this error or similar
Code:
C:\My Documents\My eBooks>cvt.bat
Processing Agatha Christie - C'Era Una Volta....rtf
Processing Agatha Christie - C'E Un Cadavere In Biblioteca.rtf
Traceback (most recent call last):
  File "convert_from.py", line 207, in <module>
  File "convert_from.py", line 120, in main
  File "convert_from.py", line 82, in process_file
IOError: [Errno 2] No such file or directory: "C:\\My Documents\\My eBooks\\Agatha Christie - C'E Un Cadavere In Biblioteca.rtf"

C:\My Documents\My eBooks>
CVT.BAT file is:
Code:
@echo off
FOR /F "tokens=*" %%a IN ('dir /b "*.rtf"') DO (
  echo Processing %%a
  echo %%a | sed -e "s/\(.*\) - \(.*\)\.[rR][tT][fF]/\"C:\\Program Files\\libprs500\\rtf2lrf\" -a \"\1\" -t \"\2\" --category=Brivido --encoding=utf-8 --base-font-size=8 \"%%a\">NUL/" > tmp_.bat
  call tmp_.bat
  pause
  del tmp_.bat >NUL
)
Offending Filename from explorer is:
Code:
Agatha Christie - C'È Un Cadavere In Biblioteca.rtf
Anyone has tips on this?

Thanks,
Xixix.
xixix is offline   Reply With Quote