Offset Offset - 20 days ago 5
C# Question

Regex In notepad ++ how do I add prefix 0x to everything after the =

I have this so far find ([0-9A-Fa-f]{2}) and replace with ,0x\1 but this add 0x in front every 2 chars with match expression. How can I only apply this ([0-9A-Fa-f]{2}) after the =

Exmaple:

TV = 0xB11BAB56
CAT = 0x9D3DCB7A


What I need:

TV = 0xB1, 0x1B, 0xAB, 0x56
CAT = 0x9D, 0x3D, 0xCB, 0x7A

Answer

For your specific example, I'd use something like replace = 0x([0-9A-Fa-f]{2})([0-9A-Fa-f]{2})([0-9A-Fa-f]{2})([0-9A-Fa-f]{2}) with = 0x\1, 0x\2, 0x\3, 0x\4