Hi, Am Montag, 26. Okt 2009, 18:40:20 +0900 schrieb Robert Klemme: > If you just want the boolean information whether the open succeeded or > not you can do this: > > irb(main):010:0> File.open("mm").close || true rescue false > => true > irb(main):011:0> File.open("not existent").close || true rescue false > => false If you just want to test then ask: File.stat("xx").readable? As Robert pointed out it is better straight to do what you want to do and catch the exceptions where they happen. Bertram -- Bertram Scharpf Stuttgart, Deutschland/Germany http://www.bertram-scharpf.de