From: Gaurang Shah Date: 2011-07-22T00:35:39+09:00 Subject: Re: How to find the character in string yes you are right my string doesn't contain "\\", however I am using that in sub function with "\\" coz "\" is a escape character. Hans Mackowiak wrote in post #1012177: > its because "\\" is not in your string see my post in your other thread > > and > String path="C:\Gaurang\ruby\demo.xls" > is not good ruby code because it is interpreted as > String(path="C:\Gaurang\ruby\demo.xls") > with is meanless,use > path = 'C:\Gaurang\ruby\demo.xls' > or > path = "C:\\Gaurang\\ruby\\demo.xls" -- Posted via http://www.ruby-forum.com/.