[Resolved] Put all files into one map
Hi!
I have a map, wich have a lot of sub-maps. (in the submaps are a lot of files)
Now I can open all sub-maps and cut all files and past it in the main map, but if I have 100 sub-maps so thats gonna take weeks.
So thats why I want to make a little program that pasts all files in the main map.
Any ideas?
Thanks!
Re: Put all files into one map
You can use the paintpicture method of the picture box to paint all your submaps in a specific location on a picturebox, and then save that as one picture.
Re: Put all files into one map
Huh? I'm pretty a n00b....
I don't want a picture :confused:
Re: Put all files into one map
what is a map if it's not a picture?
Re: Put all files into one map
ok, woops, my fault.
With a map I mean a FOLDER where you can put files in.
Sorry!
Re: Put all files into one map
VB Code:
Private Sub Command1_Click()
Dim sMainFol As String, sCurDir As String, sFile As String
Dim colFolders As New Collection
sMainFol = "C:\New Folder\" 'Remember to include \
colFolders.Add sMainFol
Do While colFolders.Count
sCurDir = colFolders.Item(1)
colFolders.Remove 1
sFile = Dir$(sCurDir, vbDirectory)
Do While Len(sFile)
If Not (sFile = "." Or sFile = "..") Then
If (GetAttr(sCurDir & sFile) Or vbDirectory) = vbDirectory Then
colFolders.Add sCurDir & sFile & "\"
Else
' To Move the file:
'Name sCurDir & sFile As sMainFol & sFile
' To Copy
FileCopy sCurDir & sFile, sMainFol & sFile
End If
End If
sFile = Dir
Loop
Loop
End Sub
I've tested it, but make sure you do too
Re: Put all files into one map
You're GREAT!! :bigyello:
It works perfectly!
Thank you very much!