Index: /trunk/src/mouse_down.m
===================================================================
--- /trunk/src/mouse_down.m	(revision 533)
+++ /trunk/src/mouse_down.m	(revision 534)
@@ -181,5 +181,5 @@
 
 %% delete the current zoom rectangle
-if isfield(AxeData,'CurrentRectZoom') && ishandle(AxeData.CurrentRectZoom)
+if isfield(AxeData,'CurrentRectZoom') && ~isempty(AxeData.CurrentRectZoom) && ishandle(AxeData.CurrentRectZoom)
     delete(AxeData.CurrentRectZoom)
     AxeData.CurrentRectZoom=[];
@@ -345,5 +345,9 @@
             ObjectName=ObjectNameNew;
             set(sethandles.Name,'String',ObjectName)% display the default name in set_object
+            if isempty(ListObject)
+                ListObject={ObjectName};
+            else
             ListObject{end}=ObjectName;
+            end
             set(hhuvmat.ListObject,'String',ListObject);%complement the object list
             set(hhuvmat.ListObject_1,'String',ListObject);%complement the object list
Index: /trunk/src/nc2struct.m
===================================================================
--- /trunk/src/nc2struct.m	(revision 533)
+++ /trunk/src/nc2struct.m	(revision 534)
@@ -15,4 +15,5 @@
 %                  ListDimName=list of dimension (added information, not requested for field description)
 %                  DimValue= vlalues of dimensions (added information, not requested for field description)
+%         .Txt: error message
 %  var_detect: vector with same length as the cell array ListVarName, = 1 for each detected variable and 0 else.
 %            var_detect=[] in the absence of input cell array 
Index: /trunk/src/plot_object.m
===================================================================
--- /trunk/src/plot_object.m	(revision 533)
+++ /trunk/src/plot_object.m	(revision 534)
@@ -41,5 +41,5 @@
 hh=[];%default output
 % object representation is canceled if the field is not projected on a plane or is the same as the represented object 
-if ~isfield(ObjectData,'Type')|| isequal(ProjObject,ObjectData)|| ~strcmp(ProjObject.Type,'plane')
+if ~isfield(ObjectData,'Type')|| isequal(ProjObject,ObjectData)||~isfield(ProjObject,'Type')|| ~strcmp(ProjObject.Type,'plane')
     if ~isempty(hplot) && ishandle(hplot) && ~strcmp(get(hplot,'Type'),'axes')
         ObjectPlotData=get(hplot,'UserData');
Index: /trunk/src/proj_field.m
===================================================================
--- /trunk/src/proj_field.m	(revision 533)
+++ /trunk/src/proj_field.m	(revision 534)
@@ -1251,5 +1251,5 @@
                     return
                 else
-                    if numel(find(VarType.coord))==2% the third matrix dimension does not correspond to a space coordinate
+                    if numel(CellInfo{icell}.CoordIndex)==2% the third matrix dimension does not correspond to a space coordinate
                         nbcolor=DimValue(3);
                         DimValue(3)=[]; %number of 'color' components updated
Index: /trunk/src/read_field.m
===================================================================
--- /trunk/src/read_field.m	(revision 533)
+++ /trunk/src/read_field.m	(revision 534)
@@ -85,4 +85,8 @@
         end
         [Field,var_detect,ichoice]=nc2struct(FileName,[ParamIn.Coord_x ParamIn.Coord_y ListVar]);
+        if isfield(Field,'Txt')
+            errormsg=Field.Txt;
+            return
+        end
         for ivar=1:numel(ListVar)
             Field.VarAttribute{ivar+2}.Role=Role{ivar};
Index: /trunk/src/uvmat.m
===================================================================
--- /trunk/src/uvmat.m	(revision 533)
+++ /trunk/src/uvmat.m	(revision 534)
@@ -4459,4 +4459,7 @@
 set(handles.edit_object,'BackgroundColor',[0.7,0.7,0.7])  
 ListObject=get(handles.ListObject,'String');
+if isempty(ListObject)
+    ListObject={''};
+end
 if ~strcmp(ListObject{end},'')
     ListObject=[ListObject;{''}]; %append a blank to the list (if nort already done) to indicate the creation of a new object
