Index: main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_utils.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_utils.py	(revision 13788)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/tests/test_utils.py	(revision 13793)
@@ -129,4 +129,5 @@
         site['configuration'].next_matric_integer_2 = 1
         site['configuration'].next_matric_integer_3 = 1
+        site['configuration'].next_matric_integer_4 = 1
         self.student.matric_number = None
         #msg, mnumber = utils.setMatricNumber(self.student)
@@ -165,4 +166,11 @@
         self.assertEqual(self.student.matric_number, 'AAU/SPS/ABC/dep1/04/AGRB/00001')
         self.assertEqual(site['configuration'].next_matric_integer_3, 2)
+        # Diploma Students get a matric number with leading 'IOS'
+        # and the dp counter which is next_matric_integer_3.
+        self.student['studycourse'].certificate.study_mode = 'dp_ft'
+        self.student.matric_number = None
+        msg, mnumber = utils.setMatricNumber(self.student)
+        self.assertEqual(self.student.matric_number, 'IOE/DIP/04/00001')
+        self.assertEqual(site['configuration'].next_matric_integer_4, 2)
         # Foundation programme students don't get matric number.
         self.student.matric_number = None
Index: main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py
===================================================================
--- main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py	(revision 13788)
+++ main/waeup.aaue/trunk/src/waeup/aaue/students/utils.py	(revision 13793)
@@ -54,4 +54,7 @@
             grok.getSite()['configuration'].next_matric_integer_3 += 1
             return
+        elif student.current_mode in ('dp_ft',):
+            grok.getSite()['configuration'].next_matric_integer_4 += 1
+            return
         grok.getSite()['configuration'].next_matric_integer_2 += 1
         return
@@ -91,4 +94,9 @@
             return None, "PTP/%s/%s/%s/%05d" % (
                 faccode, depcode, year, next_integer)
+        if student.current_mode in ('dp_ft',):
+            next_integer = grok.getSite()['configuration'].next_matric_integer_4
+            if next_integer == 0:
+                return _('Matriculation number cannot be set.'), None
+            return None, "IOE/DIP/%s/%05d" % (year, next_integer)
         next_integer = grok.getSite()['configuration'].next_matric_integer_2
         if next_integer == 0:
