Expression does not match if it is located at the end of the line:
Assuming that you would like to have a result like:
Then, just try the follow regex:
The final "\b" on the regex you have provided, forces that the character "%%" can't be the last element on the target string.
Hope this helps you.