Ok, here is the newest re-write of the code. Things I've changed...
1) Data is not written to a byte array. It is written directly to file via a mapped file
2) Creates subfolders if dragging compressed folders within compressed folders
3) Creates files/subfolders using unicode-aware APIs
4) Theoretically handles +2GB files. I'll leave that to someone else to test. Very large files are handled via a loop using a pre-defined maximum chunk size. That chunk size is currently set at approximately 100MB, but you can change it higher or lower.
For testing. Create new blank form, paste attached code & run after changing the target path in Form_OLEDragDrop.
Read comments in code
Edited Yet Again. Dang copy & paste error. All fixed below
Either re-download or make following change:
Routine: Long2Size
Change from: LongLow = CLngLong2Size - 4294967295@) - 1&
Change to: LongLow = CLng(Long2Size - 4294967295@) - 1&
See post #48 for more comments, suggested enhancements/improvements.
GO BEARS!!!!
Last edited by LaVolpe; Jan 17th, 2011 at 11:13 AM.
Insomnia is just a byproduct of, "It can't be done"