here is a simple example i just whipped up for the parsing part. its a bit long but it will work for multiple tags. i hope its not too complicated for you to understand.
EDIT: im pretty sure it doesn't matter but add the bold text.Code:Option Explicit Private Sub Command1_Click() 'call the function here Me.Caption = ParseTextInBetween(Text1.Text, "<brfor=", ">") End Sub Private Function ParseTextInBetween(ByVal MyString as String, ByVal pTagStart As String, ByVal pTagStop As String) As String Dim BgnTagPos As Long, EndTagPos As Long BgnTagPos = InStr(MyString, pTagStart) 'find the start of the tag we want. If BgnTagPos Then BgnTagPos = BgnTagPos + Len(pTagStart) 'adding here so i dont have to do it 3 times in rest of the code EndTagPos = InStr(BgnTagPos, MyString, pTagStop) 'find '>' If EndTagPos Then ParseTextInBetween = Mid$(MyString, BgnTagPos, EndTagPos - BgnTagPos) 'grab the data in between BgnTagPos and EndTagPos End If End If End Function




Reply With Quote