- Код: Выделить всё
Private Sub CopyAllFiles(strDPath As String, bSplash As Boolean)
Dim ret As Long
Dim lCount As Long
Dim strNewPath As String
Dim strOldPath As String
For lCount = 1 To colPaths.Count
strOldPath = colPaths(lCount)
If bSplash Then
ret = InStrRev(strOldPath, "\")
strNewPath = Mid(strOldPath, ret)
ret = CopyFileEx(strOldPath, strDPath & strNewPath, AddressOf CopyProgressRoutine, ByVal 0&, bCancel, COPY_FILE_RESTARTABLE)
Else
strNewPath = Right(strOldPath, Len(strOldPath) - iPath)
ret = CopyFileEx(strOldPath, strDPath & strNewPath, AddressOf CopyProgressRoutine, ByVal 0&, bCancel, COPY_FILE_RESTARTABLE)
End If
If ret = 0 Then MsgBox "Ошибка копирования: " & strOldPath
frmMain.ProgressBar1.Value = (lCount / colPaths.Count) * 100
frmMain.lblCurrFile = strNewPath & ". Файл " & lCount & " из " & colPaths.Count & " "
Next
End Sub
Кто знает в чём трамблз?