Using multiple conditions in the Do Loop structure with the Like operator do not always evaluate properly. In such cases, the use of Exit Do helps. For example, the following Do Loop condition is never true:
Do Until g_str Like "*PAGE*" Or g_str Like "*[#]*[#]*[#]*"
g_str = .ReadLine 'This method is inside a With block.
'Other stuff goes here.
Loop
However, the following works as planned: Do g_str = .ReadLine 'This method is inside a With block.
If g_str Like "*PAGE*" _
Or g_str Like "*[#]*[#]*[#]*" Then Exit Do
'Other stuff goes here.
Loop