From 1c62db0ba7d4687db7a3376b2ce3bd74fa506755 Mon Sep 17 00:00:00 2001 From: apo Date: Fri, 24 Mar 2006 08:36:52 +0000 Subject: [PATCH] Fix for Bug IPAL11942 "AttributeError" is raised by "CreatePrsForMed()". --- src/VISU_SWIG/visu.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/VISU_SWIG/visu.py b/src/VISU_SWIG/visu.py index ea05e2bf..c287e79a 100644 --- a/src/VISU_SWIG/visu.py +++ b/src/VISU_SWIG/visu.py @@ -345,7 +345,9 @@ def CreatePrsForResult(theVisu, theResult, theView, thePrsTypeList, thePictureDi while aFolderIter.More() : aFolderSObj = aFolderIter.Value() aFolderIter.Next() - anAttr = aFolderSObj.FindAttribute("AttributeName")[1] + anIsFound, anAttr = aFolderSObj.FindAttribute("AttributeName") + if not anIsFound : + continue anAttr = anAttr._narrow(SALOMEDS.AttributeName); aFolderName = anAttr.Value() print " ", aFolderName -- 2.39.2