Results 1 to 15 of 15
  1. #1
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    MOVE FILES (windows xp)

    Going way back I had a batch file
    Chkdsk/v | find ".bak" > storechk.dat
    What I am looking for is I draw a lot of CAD drawings, they create many *.bak files
    the files are in many filders under D:AcltdataDWG I cannot get my batch file to read and move the
    files, I can use the slow boat by using the search command, putting in to search D:AcltdataDWG
    it will show the files and then I can Ctrl A, (highlight all the *.bak files), Ctrl X, (cut all of them)
    then move to D:AcltbakZbak folder and use the Ctrl P, (paste all the files). Sometimes I still have to
    go back and do a Delete in the search results from the D:AcltdataDwg*.bak.
    If this could be automated as it used to be it would really save a lot of time. I think some smart person
    who can use VB could make this happen. I had a contact Ben... in Memphis, but he is no longer avaiable
    :-(, but he was really great in Access & VB. I am not. I am still keeping file names in 8*3 Example:BunBag.dwg this of course is a 6&3 example, but you get the idea. I still shell out to dos for
    all my file copies. Sorry just an old man who did not get to go to school on VB, but I would have loved too!
    Richard-Memphis <img src=/S/bow.gif border=0 alt=bow width=15 height=15>
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: MOVE FILES (windows xp)

    It's not quite clear to me what exactly you want. You state that you have many .bak files in many folders under D:AcltdataDWG. Should they all be moved into D:AcltbakZbak itself, or should they be moved to a subfolder structure under D:AcltbakZbak that mirrors the subfolder structure under D:AcltdataDWG?

  3. #3
    Platinum Lounger
    Join Date
    Jan 2001
    Location
    Quedgeley, Gloucester, England
    Posts
    5,333
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: MOVE FILES (windows xp)

    If you could make a copy of your BATch file, but give it the extension .TXT, you could Attach the TXT file to your next post and someone could have a look to see if they can work out what it does...

    John
    <font face="Script MT Bold"><font color=blue><big><big>John</big></big></font color=blue></font face=script>

    Ita, esto, quidcumque...

  4. #4
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: MOVE FILES (windows xp)

    Hans, thanks for the reply, I move all the *.bak files into the Zbak folder and then I have seperate Zipped folders which I save the *.bak files to, this was to reduce disk useage and when I do my backup of the D:AcltdataDwg files there are
    no *.bak files left in the many folders where they are created.
    The older file was used for a little different function but here is how it reads
    echo off
    cls
    rem find all .bak filses using the basic move them
    chkdsk /v | find ".bak" >basicbak.dat
    echo "the following the following files will be moved"
    type basicbak.dat
    query Do you want all (bak files) moved ? @yn *
    if errorlevel 2 goto no
    if errorlevel 1 goto yes

    I do not care about being asked, I just would like to move the *.bak files automatically into the Zbak folder
    I did not type the rest of the batch file
    :yes and the :no etc.
    I hop this helps John Gray as well ?, Thank you both for the response.....
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

  5. #5
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: MOVE FILES (windows xp)

    John will no doubt come up with a very clever solution, but does this batch file do what you want?
    <code>
    XCOPY D:AcltdataDWG*.bak D:AcltbakZbak /s
    DEL /s D:AcltdataDWG*.bak
    </code>
    (Copy into a text file with extension .bat. Run by double clicking the .bat file)

  6. #6
    Platinum Lounger
    Join Date
    Jan 2001
    Location
    Quedgeley, Gloucester, England
    Posts
    5,333
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: MOVE FILES (windows xp)

    How things have changed! CHKDSK /V doesn't list files any more!

    Try
    DIR C:*.BAK /S
    instead, and see what you get - you may need to start at a different directory, though, say
    DIR "C:start directory*.BAK" /S

    But if you say you don't care about being asked, and therefore don't need to see what files will be copied, why not strip all the BATch code out up to the :YES label?

    John

    PS Having posted the above, I see that Hans has understood the problem rather better than I!
    <font face="Script MT Bold"><font color=blue><big><big>John</big></big></font color=blue></font face=script>

    Ita, esto, quidcumque...

  7. #7
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: MOVE FILES (windows xp)

    I got an error "Cannot preform a cyclic copy"
    I tried changing to D:AcltdataDWG and then I think I typed xcopy d:dwg*.bak /s D:AcltdataZbak
    this seemed to work, but I did not get just the files in Zbak, I got the file folders and the files
    I can do this is windows XP with the Search command then when it finds the *.bak files
    I can use Ctrl A which picks all the files, I can use Ctrl X which cuts the files, I then change to D:Acltdata
    highlight the Zbak folder and use Ctrl P. sometimes I have to go back and delete the files on a second search
    I am trying to automate the because it is on a daily basis I have to perform this function.
    I do appreciate someone trying to assist me ..... any other suggestions ? I am only trying to move the *.bak files, but
    not the folders the are in. I used the pause command to test this batch file in sections.
    ECHO OFF
    D:
    PAUSE
    DIR
    PAUSE
    XCOPY D:AcltdataDWG*.BAK D:AcltdataDWGZbak /S
    I had to modify the above, but I did it from the command prompt as a test after using the CD dwg command
    I was then in D:Acltdatadwg
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

  8. #8
    Platinum Lounger
    Join Date
    Jan 2001
    Location
    Quedgeley, Gloucester, England
    Posts
    5,333
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: MOVE FILES (windows xp)

    > I got an error "Cannot preform a cyclic copy"
    > XCOPY D:AcltdataDWG*.BAK D:AcltdataDWGZbak /S

    This is not surprising, because Zbak is a subdirectory of DWK, which you have selected by using the /S switch!
    So at some point you are asking XCOPY to copy all the .BAK files in the subdirectory Zbak to the subdirectory Zbak, which is 'cyclic'.

    You have to chose another target directory which is not a subdirectory of DWG
    or use another command-line copy program which allows you to exclude specific directories from being copied, such as ROBOCOPY or XXCOPY.
    These are more complicated programs and may well need to be downloaded from the internet, so please say which route you wish to go!

    John
    <font face="Script MT Bold"><font color=blue><big><big>John</big></big></font color=blue></font face=script>

    Ita, esto, quidcumque...

  9. #9
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: MOVE FILES (windows xp)

    My computer has crashed a couple of times, I would like to use either of the programs, where would I obtain them the
    Robocopy or the XXcopy(sounds bad XX) I am willing to move the copy to folder, I could keep it under Acltdata but out of the
    DWG folder ... ?
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

  10. #10
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: MOVE FILES (windows xp)

    Do a Google search...

  11. #11
    Platinum Lounger
    Join Date
    Jan 2001
    Location
    Quedgeley, Gloucester, England
    Posts
    5,333
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: MOVE FILES (windows xp)

    As always, Google is your friend!

    For the XP version of ROBOCOPY you need to download the Windows Server 2003 Resource Kit Tools, all 11.3 MB of them, and extract ROBOCOPY.* from the large number of other tools. (Yes, this is for XP as well as 2003...)

    For XXCOPY (just eXtended XCOPY, nothing sinister) try the XXCOPY website.

    You will need to read the Help information because each has more switches than you would believe possible...

    John
    <font face="Script MT Bold"><font color=blue><big><big>John</big></big></font color=blue></font face=script>

    Ita, esto, quidcumque...

  12. #12
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: MOVE FILES (windows xp)

    I would like to move all the bak files from many subfolders into the (1) sub folder called Zbak, I then use Winzip to move them into seperate Zip files based on their prefix, Example BR00.BAK, BU00.BAK, HB00.BAK, BL00.BAK, BS00.BAK
    Everytime I work on a CAD drawing it makes the .bak file. I just save them in a folder and zip them at least 2-3 times a week
    I also have a briefcase backkup the DWG folder, but it wants to take all the .bak files as well, that is why I move them first.
    but I have to do it manually.
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

  13. #13
    Super Moderator
    Join Date
    Dec 2000
    Location
    Renton, Washington, USA
    Posts
    12,560
    Thanks
    0
    Thanked 4 Times in 4 Posts

    Re: MOVE FILES (windows xp)

    What do you use these "BAK" (backup) files for?

    If I remember right when I was using AutoCAD, they were NOT worth having around once you opened the master file, as AutoCAD will make new ones. When I was still working, we have "BAT files" that went in a DELETED all of the BAK files just to help keep the hard drive clean.

    Now running HP Pavilion a6528p, with Win7 64 Bit OS.

  14. #14
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: MOVE FILES (windows xp)

    Thank you for the reply, I found a Techinical Bulletin on it.
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

  15. #15
    2 Star Lounger rjbphillipsiii's Avatar
    Join Date
    Mar 2003
    Location
    Memphis, Tennessee, USA
    Posts
    187
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: MOVE FILES (windows xp)

    Thanks for the input, but I have had a few times my computer crashed and Corrupted the .dwg file and I was able to retrieve the .bak file, rename to .dwg and pickup where I was.... Richard
    R.J.B. Phillips III
    Logical Systems Inc. Part Time Drafter
    IBC WONDER HOSTESS Retired 33+ years
    Firestone Tr & Rubber Company 15 Years rjbphillipsiii@yahoo.com

Posting Permissions

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