1. Strings de interceptação pura
A cópia do código é a seguinte:
functionCutstr (theST1, strlen)
DIML, T, c
l = len (theST1)
IFL <1ThenexitFunction
t = 0
fordxy1 = 1tol
C = ABS (ASC (MID (TheST1, DXY1,1)))))
IFC> 255THEN
t = t+2
outro
t = t+1
endif
ift> = strlenthen
thev = MID (theST1,1, dxy1)
exitfor
outro
thev = theST1
endif
próximo
cutstr = thev
Função final
2. Intercepte a corda, use espaços para preenchê -la
A cópia do código é a seguinte:
functionCutstr (theSt, strlen)
DIML, T, c
L = Len (theST)
t = 0
fordxy = 1tol
C = ABS (ASC (MID (TheST, DXY, 1)))))
IFC> 255THEN
t = t+2
outro
t = t+1
endif
ift> = strlenthen
thev = esquerda (test, dxy)
exitfor
outro
bu = strlen-t
Forbui = 1Tobu
strbu = ""
strbuall = strbuall & strbu
próximo
thev = theSt & strbull
strbu = ""
strbuall = ""
endif
próximo
cutstr = thev
Função final