The '0' characters behind the specified string are cut off [Original]

xiaoxiao2021-03-06  42

{------------------------------------- ------------------------------ procedure name: TForm1.RTrimZero author: Kevin date: 2004.12.22 parameters: const AValue: string Return Value: String Features: Cut 0 characters behind the specified string -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------} Function TFORM1.RTRIMZERO (const): string; var nlen: integer; I: integer; startemp: string; begin if (avalue = ') THEN RESULT: ='; Nlen: = Length; For i: = nlen downto 1 do begin if (Avalue [i] = '0') Then Strtemp [i]: = '' else break; end; result: = strTemp;

转载请注明原文地址:https://www.9cbs.com/read-77932.html

New Post(0)