doesn't make sense, which is why the compiler doesn't like it.
It doesn't make sense, because you haven't told the compiler what type StringBuffer is.
I'm with AMOL, though. Ditch the whole damned String class and learn to use the underlying NULL terminated char array.