Results 1 to 7 of 7

Thread: [RESOLVED] display progress when copy/delete/move files

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jan 2007
    Posts
    128

    Resolved [RESOLVED] display progress when copy/delete/move files

    is there a way to display the progress when copying/deleting/moving a lot of files..maybe a progress bar... or somekind of messagebox(with no buttons...dunno how to call that) where there's a progress of the kind
    (" copying myfile.bin ") without freezing the program... i noticed when i am copying a lot of files...the application freezes until copying complete..

    i tried to use threads but with no success...i read threads not recommended in vb 6.0

  2. #2
    "Digital Revolution"
    Join Date
    Mar 2005
    Posts
    4,471

    Re: display progress when copy/delete/move files

    So long as you know the total number of files you're working with.

    You could set the progress bar's max property to total number of files and increment it by one before you move on to the next one.

    Or keep the min/max values at 0 and 100 and calculate a percentage value and set the progress to that. This is a good way if the total number of files is greater than the .Max property can store.

    Otherwise, the first method is the easiest.

  3. #3
    PowerPoster gavio's Avatar
    Join Date
    Feb 2006
    Location
    GMT+1
    Posts
    4,462

    Re: display progress when copy/delete/move files

    Setting .Max property to number of files is not such a good of idea - if you have 2 files, first one is 10 GB big, and the next one is 1 MB big, the progress will show 50% when you'll copy the first one... you can see the rest.

  4. #4

    Thread Starter
    Addicted Member
    Join Date
    Jan 2007
    Posts
    128

    Re: display progress when copy/delete/move files

    ey but when i copy files from one folder to another.... my whole application feezes..so the progress bar doesn't even move..it moves just when all copying was done...

  5. #5

  6. #6
    Learning .Net danasegarane's Avatar
    Join Date
    Aug 2004
    Location
    VBForums
    Posts
    5,853

    Re: display progress when copy/delete/move files

    Why dont you try this one
    Please mark you thread resolved using the Thread Tools as shown

  7. #7

    Thread Starter
    Addicted Member
    Join Date
    Jan 2007
    Posts
    128

    Re: display progress when copy/delete/move files

    i find the solution
    http://www.vbforums.com/showthread.p...ress+copy+file

    next i will use search before posting... srry just thought this kind of question wud be hard to search

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width