Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Copy files with Pause/Resuming
#1
Is possible copy files with Pause/Resuming like http://www.ranvik.net/totalcopy/ in QM?
#2
I would at first try CopyFileEx. It allows you to pause/resume.
#3
Can you show me an example?
#4
Maybe some day later.
#5
It can today be?
#6
Sorry, no. This month I'm especially busy.
#7
It can today be?
#8
Lucas Wrote:It can today be?
try doing the code yourself while waiting 8) i will read up on what he said and give you some pointers 8)
Smile 8)
#9
Code:
Copy      Help
str sfrom sto
;sfrom="F:\1830_usa_ddk.iso"
;sto="F:\1830_usa_ddk_2.iso"

sfrom="\\GINTARAS\F\1830_usa_ddk.iso" ;;236 MB
sto.expandpath("$desktop$\1830_usa_ddk.iso")

;cop sfrom sto

int canceled
;if(!CopyFileEx(sfrom sto &CFE_Progress 0 &canceled COPY_FILE_RESTARTABLE))
if(!CopyFileEx(sfrom sto 0 0 &canceled COPY_FILE_RESTARTABLE))
,;out canceled
,end _s.dllerror

;CopyFileEx supports resuming, but then it is much slower.
;I tested on 100Mbs network. Speed was (% of network speed):
;;;cop - 85%.
;;;CopyFileEx without COPY_FILE_RESTARTABLE - 85%.
;;;CopyFileEx with COPY_FILE_RESTARTABLE - 33%.


;CopyFileEx itself does not show a progress dialog.
;If eg network connection is lost while copying, CopyFileEx
;fails and leaves partially copied file. When calling next time,
;it resumes copying.
#10
Thanks.

I thought that it would be more useful...


Forum Jump:


Users browsing this thread: 1 Guest(s)