Index: /issm/trunk/src/m/classes/public/ProcessPatch.m
===================================================================
--- /issm/trunk/src/m/classes/public/ProcessPatch.m	(revision 4240)
+++ /issm/trunk/src/m/classes/public/ProcessPatch.m	(revision 4240)
@@ -0,0 +1,28 @@
+function structure=ProcessPatch(structure,step,Patch);
+%PROCESSPATCH - create a structure from a patch
+%
+%   Usage:
+%      Result=ProcessPatch(Patch);
+
+%Get number of fields;
+fields=unique(Patch(:,1));
+
+%parse fields
+for i=1:length(fields),
+
+	%get name
+	fieldname=EnumAsString(fields(i));
+
+	%get line positions
+	pos=find(Patch(:,1)==fields(i));
+
+	%Fill Result structure
+	%structure(step).(fieldname).steps=Patch(pos,2);
+	%structure(step).(fieldname).time=Patch(pos,3);
+	structure(step).(fieldname).element=Patch(pos,4);
+	structure(step).(fieldname).interpolation=Patch(pos,5);
+	structure(step).(fieldname).index=Patch(pos,6:8);
+	structure(step).(fieldname).value=Patch(pos,9:end);
+
+end
+
Index: /issm/trunk/src/m/classes/public/parseresultsfromdisk.m
===================================================================
--- /issm/trunk/src/m/classes/public/parseresultsfromdisk.m	(revision 4239)
+++ /issm/trunk/src/m/classes/public/parseresultsfromdisk.m	(revision 4240)
@@ -16,7 +16,16 @@
 while ~isempty(result),
 
+	%Get time and step
 	results(result.step).step=result.step;
 	results(result.step).time=result.time;
-	results(result.step).(result.fieldname)=result.field;
+
+	%process patch if necessary
+	if strcmpi(result.fieldname,'Patch'),
+		results=ProcessPatch(results,result.step,result.field);
+	else
+		results(result.step).(result.fieldname)=result.field;
+	end
+
+	%read next result
 	result=ReadData(fid);
 
