VBA Use InStrRev to find the position of the last instance of a substring
Const baseString As String = "Foo Bar"
Dim containsBar As Boolean
'Find the position of the last "B"
Dim posX As Long
'Note the different number and order of the parameters for InStrRev
posX = InStrRev(baseString, "X", -1, vbBinaryCompare)
'posX = 0