String conversion: How to replace backslash with forward slash?

Hello. I've tried a number of solutions I found here ("") but can't get any of them to work.

I'm trying to replace "\" with "/" in a folderpath. I started with


but that expression replaces "\" with nothing.

I've tried various ways of escaping the "\" and "/" but nothing works. I can't get the $regex solutions I've seen to work either. Can anyone help?

PS Replacing "\" with "\\" as I need to do for this post to read correctly doesn't work either...

the forward slash is an invalid character for a filename or path.