+ Reply to Thread
Results 1 to 9 of 9

move files to folder based on a .igy list

  1. #1
    Registered User
    Join Date
    11-08-2012
    Location
    arity
    MS-Off Ver
    Excel 2003
    Posts
    9

    move files to folder based on a .igy list

    Hello,

    I have a problem with file moving.
    I have a .iqy (web based excel list) which is contanty updated. On the other hand I have a folder with files(pdfs and autocad) that have a specific name that matches(or doesn't) with one from the igy file.

    Now I really want to automated this and it is driving me crazy. Can anyone help me with this?
    What I am looking for is that I open the .iqy file. Then select the macro and let it run in the folder that I need to check. And then the files that are
    not in the list should be moved to a folder and the ones that are in the list to another folder.

    Hope someone can help me. (I have limited VBA skill but am willing to try anything!)

    best regards,

  2. #2
    Registered User
    Join Date
    11-08-2012
    Location
    arity
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: move files to folder based on a .igy list

    little bump!

    Made it even easier, I have a .txt list of the all the files and in a folder I have files that are either in the list or not.
    I would like then to be seperated into 2 folders according to the .txt list file..

  3. #3
    Forum Expert OllieB's Avatar
    Join Date
    12-20-2012
    Location
    Netherlands
    MS-Off Ver
    Excel 2007 (home) & 2010 (office)
    Posts
    1,542

    Re: move files to folder based on a .igy list

    I will be quite honest, I am too lazy to set-up the whole test environment!

    So the code below is untested but it should work with perhaps one or two minor corrections

    Please Login or Register  to view this content.
    If you like my contribution click the star icon!

  4. #4
    Registered User
    Join Date
    11-08-2012
    Location
    arity
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: move files to folder based on a .igy list

    Thank you for your reply.
    I am having trouble using your code. With what can I use the code?
    Should I open excel? or create a bat file of it?
    Because I don't know how to use your code...
    I am a real beginner...

    thanks on forehand!

  5. #5
    Forum Expert OllieB's Avatar
    Join Date
    12-20-2012
    Location
    Netherlands
    MS-Off Ver
    Excel 2007 (home) & 2010 (office)
    Posts
    1,542

    Re: move files to folder based on a .igy list

    Henk,

    I have provided a VBA routine which can be executed from within Excel (kind of like a macro). If you do not know how to use this then perhaps we should stop here, because explaining everything from scratch (including the likely debugging that will be needed) would be a bit too cumbersome for me.

  6. #6
    Registered User
    Join Date
    11-08-2012
    Location
    arity
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: move files to folder based on a .igy list

    Hi,

    I am sorry for the low level of skills, I managed to create a VBA routine and it gave an error 450 in :
    dctFileList.Add strFileName

    I think I managed to let it run...
    But maybe I need some more lessons in how to use VBA.

    cheers

  7. #7
    Forum Expert OllieB's Avatar
    Join Date
    12-20-2012
    Location
    Netherlands
    MS-Off Ver
    Excel 2007 (home) & 2010 (office)
    Posts
    1,542

    Re: move files to folder based on a .igy list

    No apology needed. It is just difficult to support remotely

  8. #8
    Registered User
    Join Date
    11-08-2012
    Location
    arity
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: move files to folder based on a .igy list

    I keep getting the same error:
    error 450 in :
    dctFileList.Add strFileName

    what does this mean?
    I managed to move alle the files already with excel/VBA but now it must be by the list!

    thanks

  9. #9
    Forum Expert OllieB's Avatar
    Join Date
    12-20-2012
    Location
    Netherlands
    MS-Off Ver
    Excel 2007 (home) & 2010 (office)
    Posts
    1,542

    Re: move files to folder based on a .igy list

    Change the line to

    Please Login or Register  to view this content.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1