Hi,
I will try and explain my problem to the best of my ability. I have some code that access' 2 MySQL tables and retrives some values, one of these being a set of regular expressions, and the other being the stings that i wish to test the regular expression on. The problem occurs when i try and loop around these values, my first loop is to loop around the regular expressions, and the sencond loop is to loop around the strings to match against the regular expression.
When i step through the debugger is say i am using an invalid use of null on the following line :Code:Do Until rdoRsReg.EOF With rdoRsReg objRE.Pattern = !Regexpression objRE.Global = True Do Until rdoRS.EOF With rdoRS Set objMatches = objRE.Execute(!Query_text) If objMatches.count > 0 Then For Each objMatch In objMatches Text2.Text = Text2.Text + vbCrLf & !Query_ID & objMatch.Value '"Sentence end found at position " & objMatch.FirstIndex Next Else Text2.Text = Text2.Text & "The expression was not found" End If rdoRS.MoveNext End With Loop rdoRsReg.MoveNext End With Loop
To begin with the !Query_text is holding a correct value from the table, but when i step past it, it the turns to null and errors.Code:Set objMatches = objRE.Execute(!Query_text)
Any help would be great
I hope i have explained my problem clearly, if not please ask for more detail![]()




Reply With Quote