the good question is "why do you need to do this ?"... I suspect a dark reason which is in fact because you're trying to hack something because you don't actually understand that string escaping is useful only in your source code... if you're getting the string from an external source (input, textbox, open file dialog), the string you get is already good. you need to escape \ into \\ only in your source code, because if you don't, the \ character will try to escape the character next to it, and that's not what you want. you want a single \ in the string, because it is the folder separator character, which must be typed '\\'...
[VisualCalc][Binary Guide][CommDialogs] | [Forums Guidelines]