Replace string escape in an expression

I am trying to edit the value returned from the file explorer component selected path. My selected path would be like [color=#0000BF]P:\OWSTransfer\Scanner_INI\EC_first.INI[/color] and i want to replace the [color=#0000BF]P:\OWSTransfer\Scanner_INI[/color] with [color=#0000BF]C:[/color] to have a result of [color=#0000BF]C:\EC_first.INI[/color]

replace("{Root Container.ChainRails 2.File Explorer.selectedPath}", “P:\OWSTransfer\Scanner_INI”, “C:”)

The error reads
Scan Error: Illegal escape sequence"\O| (Line1 , Char 72)

I have also tried

replace("{Root Container.ChainRails 2.File Explorer.selectedPath}", escapeXML(“P:\OWSTransfer\Scanner_INI”), “C:”)

With similar error

So how do I escape in an Expression?

I got help here from another guy should read:

replace({Root Container.ChainRails 2.File Explorer.selectedPath}, "P:\\OWSTransfer\\Scanner_INI", "C:")

Yup, you got it - have to escape the escape character.