Berikut format memanipulasi string dalam delphi Chr(<Integer>); Copy(<SourceString>, <start pos>, <length>); CompareStr(<SourceString1>, <SourceString2>); Delete(<SourceString>, <start pos>, <length>); IntToStr(<SourceInteger>); Insert(<fromSourceString>, <toSourceString>, <start pos>); Length(<SourceString>); Pos(‘<find this>’, <SourceString>); SetLength(<SourceString>, <length>); StringOfChar(‘<Character>’, <quantity>); StrPas(<PCharString>); StrPCopy(<SourceString>); StrToInt(<SourceString>); StrToIntDef(<SourceString>, <DefaultInteger>); StrTo<???>(<SourceString>); <???>ToStr(<Source???>); ??? = Float, Currency, Date, Time, DateTime StringReplace(<SourceString>, ‘<replace this>’, ‘<with this>’, [rfReplaceAll]); Trim(<SourceString>); trim l/r blanks TrimLeft(<SourceString>); [...]
Filed under: Programing, Tutorial Pascal / Delphi | 1 Comment »