Dim code(20) As String
    Dim Count As String
    Count = 0
    code(0) = xProfile.FirstValue("SendNUM")
    If code(0) <> "" Then
        Do
          Count = Count + 1
          code(Count) = xProfile.NextValue
          If code(Count) = "" Then Exit Do
        Loop
    End If
    readAllCode = code'以下是xprofile的定义:
Private Function RetStr() As String
     Dim i As Long
     i = InStr(Start, buf, Chr(0))
     If i > Start Then
       RetStr = Mid(buf, Start, i - Start)
     End If
     Start = i + 1
End Function
  
Public Function FirstValue(ByVal clsName As String) As String
     Ret = GetPrivateProfileSection(clsName, buf, BufSize, filename)
     Start = 1
     FirstValue = RetStr()
End Function
Public Function NextValue() As String
     NextValue = RetStr()
End Function