Advertisement
here2share

# error_catch.py

Sep 15th, 2015
223
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.18 KB | None | 0 0
  1. # error_catch.py
  2.  
  3. varFakeFolder = 'FakeFolder'
  4. try:
  5.     with open('C:/Test/' + varFakeFolder + '/fakefile.txt') as f:
  6.         content = f.readlines()
  7. except IOError as ErrID:
  8.     print ErrID
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement