convert Unix path to DOS path

Change all forward slashes into backslashes

Download todospath.zip

Synopsis:

todospath.py


todospath.py

Synopsis
def toDosPath(path):
   return path.replace('/', '\\')

#-- unit tests
def test_todospath():
   ut.utassert(toDosPath("c:/bin/bob"), "c:\\bin\\bob")






Contact me about content on this page using john_web-at-arrizza-dot-com
For Web Master or site problems contact: webadmin-at-arrizza-dot-com
Copyright John Arrizza (c) 2001,2002,2003,2004,2005,2006,2007