From: Peter Bailey Date: 2010-05-05T22:29:56+09:00 Subject: Re: Why can't I do a "to_i?" Calamitas wrote: > On Wed, May 5, 2010 at 2:45 PM, Peter Bailey wrote: >> �filewidth � � � �= fileinfo.match(/Width x Height: ([0-9]{1,5}) x >> ([0-9]{1,5})[1]/) >> �filedepth � � � �= fileinfo.match(/Width x Height: ([0-9]{1,5}) x >> ([0-9]{1,5})[2]/) >> �fileres � � � �= fileinfo.match(/Dots per inch: [0-9]{1,5}/) > > Maybe move [1] and [2] outside the regexps? > > Peter Yes, thanks. I found the problem. It's the placement of my [1] and [2] there at the end of the lines. Thanks for your responses. -- Posted via http://www.ruby-forum.com/.