[Tutor] try & except
Magnus Wirström
asdlinux at yahoo.se
Tue Aug 8 22:13:00 CEST 2006
Hi
I'm playing around with try: and except: i have a code like this
try:
bibl=os.listdir("c:\\klientdata\\")
except:
wx.MessageBox("Kunde inte läsa käll
biblioteket.","Säkerhetskopiering",wx.OK|wx.ICON_ERROR)
(yeah ... it's swedish :) )
So far i get how to use it but i would like to be able to execute the
try block again after it jumped to the exception. How can i make it
retry to read the directory?
Thanks
Magnus
More information about the Tutor
mailing list