public static String removeCRLF(String in){
  char[] inArray=in.toCharArray();
  StringBuffer out=new StringBuffer(inArray.length);
  for (int i=0; i < inArray.length; i++) {
    char c=inArray[i];
    if (c == '\n' || c == '\r')     ;
 else     out.append(c);
  }
  return out.toString();
}

public static String removeCRLF ( String in ) { char [ ] inArray = in . toCharArray ( ) ; StringBuffer out = new StringBuffer ( inArray . length ) ; for ( int i = 0 ; i < inArray . length ; i ++ ) { char c = inArray [ i ] ; if ( c == '\n' || c == '\r' ) ; else out . append ( c ) ; } return out . toString ( ) ; }
remove cr / lf from string
