SUBSTRING 썸네일형 리스트형 한글 byte로 자르기(깨짐 없이) 쓸때마다 새로만드는 것 같아서 저장용 UTF-8일 경우subStringBytes("블라블라블라라", 10, 3);EUC-KR일 경우subStringBytes("블라블라블라라", 10, 2); public String subStringBytes(String str, int byteLength, int sizePerLetter) { int retLength = 0; int tempSize = 0; int asc; if (str == null || "".equals(str) || "null".equals(str)) { str = ""; } int length = str.length(); for (int i = 1; i 127) { if (byteLength >= tempSize + sizePerLetter) .. 더보기 이전 1 다음