Index: /trunk/src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp	(revision 56917)
+++ /trunk/src/VBox/Frontends/VBoxManage/VBoxInternalManage.cpp	(revision 56918)
@@ -94,4 +94,6 @@
     /** partition number */
     unsigned        uIndex;
+    /** partition number (internal only, windows specific numbering) */
+    unsigned        uIndexWin;
     /** partition type */
     unsigned        uType;
@@ -831,4 +833,5 @@
                 PHOSTPARTITION pCP = &pPart->aPartitions[pPart->cPartitions++];
                 pCP->uIndex = currentEntry + 1;
+                pCP->uIndexWin = currentEntry + 1;
                 pCP->uType = 0;
                 pCP->uStartCylinder = 0;
@@ -843,4 +846,5 @@
                 {
                     pCP->uIndex = 0;
+                    pCP->uIndexWin = 0;
                     --pPart->cPartitions;
                     break;
@@ -867,4 +871,5 @@
 
         unsigned uExtended = (unsigned)-1;
+        unsigned uIndexWin = 1;
 
         for (unsigned i = 0; i < 4; i++)
@@ -890,5 +895,8 @@
             {
                 if (uExtended == (unsigned)-1)
+                {
                     uExtended = (unsigned)(pCP - pPart->aPartitions);
+                    pCP->uIndexWin = 0;
+                }
                 else
                 {
@@ -896,4 +904,9 @@
                     return VERR_INVALID_PARAMETER;
                 }
+            }
+            else
+            {
+                pCP->uIndexWin = uIndexWin;
+                uIndexWin++;
             }
         }
@@ -931,4 +944,5 @@
                 PHOSTPARTITION pCP = &pPart->aPartitions[pPart->cPartitions++];
                 pCP->uIndex = uIndex;
+                pCP->uIndexWin = uIndexWin;
                 pCP->uType = p[4];
                 pCP->uStartCylinder = (uint32_t)p[3] + ((uint32_t)(p[2] & 0xc0) << 2);
@@ -954,5 +968,7 @@
                 else if (PARTTYPE_IS_EXTENDED(p[4]))
                 {
-                    uExtended = uIndex++;
+                    uExtended = uIndex;
+                    uIndex++;
+                    uIndexWin++;
                     uOffset = RT_MAKE_U32_FROM_U8(p[8], p[9], p[10], p[11]);
                 }
@@ -1658,10 +1674,10 @@
                     RTStrAPrintf(&psz, "\\\\.\\Harddisk%sPartition%u",
                                  rawdisk.c_str() + 17,
-                                 partitions.aPartitions[i].uIndex);
+                                 partitions.aPartitions[i].uIndexWin);
                     if (!psz)
                     {
                         vrc = VERR_NO_STR_MEMORY;
-                        RTMsgError("Cannot create reference to individual partition %u, rc=%Rrc",
-                                   partitions.aPartitions[i].uIndex, vrc);
+                        RTMsgError("Cannot create reference to individual partition %u (numbered %u), rc=%Rrc",
+                                   partitions.aPartitions[i].uIndex, partitions.aPartitions[i].uIndexWin, vrc);
                         goto out;
                     }
