diff --git a/invesalius/data/surface.py b/invesalius/data/surface.py index 16500f4..37bf290 100644 --- a/invesalius/data/surface.py +++ b/invesalius/data/surface.py @@ -360,10 +360,13 @@ class SurfaceManager(): actor.GetProperty().SetColor(colour) actor.GetProperty().SetOpacity(1-surface.transparency) - #Remove all temp file - os.remove(filename_img) - os.remove(filename_polydata) - + try: + #Remove all temp file + os.remove(filename_img) + os.remove(filename_polydata) + except(WindowsError): + print "Error remove temp file" + # Append surface into Project.surface_dict proj = prj.Project() index = proj.AddSurface(surface) -- libgit2 0.21.2