Imports System.Text.RegularExpressions Public Module TableUtility Public Function SearchKey(sLine As String, sKey As String) As String Return Regex.Match(sLine, "[,|{|\s]" & sKey & "\s*=\s*['|\""]?(.*?)\s*?[,|}|'|\""]").Groups(1).Value End Function Public Function CountCharacter(ByVal sLine As String, ByVal cValue As Char) As Integer Dim nCount As Integer = 0 Dim cArray() As Char = sLine.ToCharArray For Index As Integer = 0 To cArray.Count - 1 If cArray(Index) = cValue Then nCount += 1 Next Return nCount End Function End Module