m_vb1386
پنج شنبه 18 مهر 1387, 12:49 عصر
Dim file() As String
Private Sub Form_Load()
CommonDialog1.Flags = 524800
KewlButtons3.Visible = False
End Sub
Private Sub KewlButtons1_Click()
Dim new_file As New FileSystemObject
If new_file.FolderExists("c:\test") Then
new_file.DeleteFolder ("c:\test")
new_file.CreateFolder ("c:\test")
Else
new_file.CreateFolder ("c:\test")
End If
End Sub
Private Sub KewlButtons2_Click()
List1.Clear
CommonDialog1.ShowOpen
file = Split(Me.CommonDialog1.FileName, vbNullChar)
For i = 1 To UBound(file)
List1.AddItem file(i)
Next
KewlButtons3.Visible = True
End Sub
Private Sub KewlButtons3_Click()
For i = 1 To UBound(file)
FileCopy file(0) & "\" & file(i), "c:\test\" & "a" & i & ".mdb"
Next
End Sub
وقتی تعداد فایلها زیاد میشه خطا میده برنامم رو چجوری اصلاح کنم
Private Sub Form_Load()
CommonDialog1.Flags = 524800
KewlButtons3.Visible = False
End Sub
Private Sub KewlButtons1_Click()
Dim new_file As New FileSystemObject
If new_file.FolderExists("c:\test") Then
new_file.DeleteFolder ("c:\test")
new_file.CreateFolder ("c:\test")
Else
new_file.CreateFolder ("c:\test")
End If
End Sub
Private Sub KewlButtons2_Click()
List1.Clear
CommonDialog1.ShowOpen
file = Split(Me.CommonDialog1.FileName, vbNullChar)
For i = 1 To UBound(file)
List1.AddItem file(i)
Next
KewlButtons3.Visible = True
End Sub
Private Sub KewlButtons3_Click()
For i = 1 To UBound(file)
FileCopy file(0) & "\" & file(i), "c:\test\" & "a" & i & ".mdb"
Next
End Sub
وقتی تعداد فایلها زیاد میشه خطا میده برنامم رو چجوری اصلاح کنم