p;, ByVal 0&amp;, ByVal 0&amp;)
         For i = 1 To ImageCount
            hIcon = ImageList_GetIcon(m_hIml, i - 1, 0)
            If (hIcon &lt;&gt; 0) And (hIcon &lt;&gt; -1) Then
               SerialiseIcon lHDC, hIcon, b(), lStart, lSize, lVersion
               DestroyIcon hIcon
            End If
            lStart = lStart + lSize
         Next i
         DeleteDC lHDC
         If (lStart &gt; 0) Then
            Debug.Print "WriteImages"
            ReDim Preserve b(0 To lStart - 1) As Byte
     