Convert the StringBuffer to a String ( .toString ) and then do the substring stuff on it. Regards, Frank -----Original Message----- From: Valderrama, Eric [mailto:[EMAIL PROTECTED]] Sent: Wednesday, January 10, 2001 2:36 PM To: [EMAIL PROTECTED] Subject: How can I search for a substring in a StringBuffer object and the replace it? Hi, Please correct me if I'm wrong but there's not a method in StringBuffer class to search a substring in a StringBuffer variable and then to get the index or the position where the substring is. How can I do that? I tried to use indexOf() method but it didn't work because it belongs to String class. I hope you can help me Thanks -Eric.- ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
Re: How can I search for a substring in a StringBuffer object and the replace it?
GOSS,FRANK (Non-HP-FtCollins,ex1) Wed, 10 Jan 2001 12:56:14 -0800
- Re: How can I search for a substring in ... Willard Thompson
- Re: How can I search for a substrin... GOSS,FRANK (Non-HP-FtCollins,ex1)
- Re: How can I search for a substrin... Ramesh, Kesav
- Re: How can I search for a substrin... T A Flores
