From: Peter Bailey Date: 2006-06-14T22:03:38+09:00 Subject: Re: RUBY keeps complaining about my "end" statement Anton 'tony' Bangratz wrote: > Peter Bailey wrote: > >> cgmpr,cpslit,cpsmco,edc131,edt131,eeomc7,emgc15,hcc201,hcci01,hct201,hcti01, >> hla020,hlai20,hlb020,hlbi20,hltc20,hlti20,ierc78,itc101,jsc047,lrc013,lrfl21, >> lrnm21,lrrc21,lrrc22,lrrc24,lrrc37,lrrc49,lrrc74,lrrmc6,lrrt37,mopc68,mopd68, >> mopec8,mopt68,pgc117,pslc45,psvc45,rt013,rtc129,uln007}*.pdf") >> ps2kfiles.each do |ps2kfile| >> ftp = Net::FTP.open('quark.bna.com') >> ftp.login('xxx','xxx') >> ftp.chdir('/home/xxx') >> #ftp.chdir('/prod/data/pdf/index-wip') >> ftp.putbinaryfile(#{ps2kfile}) > > ITYM: > ftp.putbinaryfile(ps2kfile) >> end >> > > Explanation: you do not need interpolation here, the variable > 'ps2kfile' does hold the value you want already. > > Oh, and you might want to change your password(s), if they are real. > > HTH, > > t. That worked. And, it is simpler. It's not a string, anyway, so, why would I need the #{}s, right? Thank you! No, those aren't my credentials. That's a fake password and credentials. -- Posted via http://www.ruby-forum.com/.