From: Luis Lavena Date: 2010-01-12T09:20:07+09:00 Subject: Re: File::exists?( "filename with a blank in it" ) On Jan 11, 3:30 pm, Ralph Shnelvar wrote: > Newbie here/ > > Consider > > IMAGEMAGICK_EXE_PATH = '"f:\Program Files\ImageMagick-6.5.8-Q16\convert.exe"' > > (rdb:2) File::exists?( IMAGEMAGICK_EXE_PATH ) > false > > What's the right way to test if a file name which has a blank in it exists? For double quotes: use double backlashes: "F:\\Program Files\\ImageMagick..." For single quotes, it can work as is. I recommendation also is ensure all the paths are expanded with File.expand_path, which is going to ensure forward slashes are used instead. -- Luis Lavena