텍스트를 UTF-8로 저장하기
UTF8String 타입은 System 에 선언 되어 있습니다.

U: UTF8String; //변수를 하나 선언하고

// UTF-8변환
U := UTF8Encode(WideString('변환할내용'));
with TFileStream.Create('저장할파일명', fmCreate) do
try
   Write(Pointer(U)^, Length(U));
finally
  Free;
end;
 

델파이 6부터 사용할수 있는 코드 입니다. 

Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Get Adobe Flash playerPlugin by wpburn.com wordpress themes
© 2010 Namul's Blog Suffusion WordPress theme by Sayontan Sinha