GetDigits

Extracts digits out of a string


Public

Tested

My Own Work
<%
Function GetDigits(value)
dim s, sd, i
s = ""
for i = 1 to Len(value)
sd = Mid(value, i, 1)
if (Asc(sd) >= Asc("0")) and (Asc(sd) <= Asc("9")) then
s = s & sd
end if
next
GetDigits = s
End Function
%>

Views 3694 Downloads 1122

Classic ASP Texts + Strings
JeffSmith
26
Revisions

v1.0