Friday, March 15, 2013

Prevent Character Escaping - Python

http://stackoverflow.com/questions/2042342/network-path-and-variables-in-python

If you want to use network paths without adding extra slashes, you can use python's raw string function.

Here's an example of something you want to make a raw string:

source_path = r"\\mynetworkshare"

No comments:

Post a Comment