Thread
:
Check if file exists
View Single Post
#
2
09-27-2011, 10:58 AM
farshizzo
WorldViz Team Member
Join Date: Mar 2003
Posts: 2,849
You can use the
os.path.isfile
command to check for file existence.
Code:
import os if os.path.isfile('foo.txt'): print 'File exists'
farshizzo
View Public Profile
Find all posts by farshizzo