+ Reply to Thread
Results 1 to 6 of 6

Deleting Files Using FSO

  1. #1
    Registered User
    Join Date
    07-06-2007
    Posts
    70

    Question Deleting Files Using FSO

    Hi all,

    I have the following wee script which deletes pdf files in a folder.

    Is there a way i can customize so that it check all subfolders within folder?

    Please Login or Register  to view this content.
    Thanks in advance!!
    C
    Last edited by cjconnor24; 05-12-2009 at 11:00 AM. Reason: pasted wrong macro

  2. #2
    Forum Guru
    Join Date
    08-26-2007
    Location
    London
    Posts
    4,606

    Re: Deleting Files Using FSO

    The Folders object has a SubFolders property.

  3. #3
    Registered User
    Join Date
    07-06-2007
    Posts
    70

    Re: Deleting Files Using FSO

    Thanks Stephen,

    Any idea how i would work that into my macro?

  4. #4
    Forum Guru
    Join Date
    08-26-2007
    Location
    London
    Posts
    4,606

    Re: Deleting Files Using FSO

    Does your code work as is? Why is it a function? Try this:
    Please Login or Register  to view this content.

  5. #5
    Registered User
    Join Date
    07-06-2007
    Posts
    70

    Re: Deleting Files Using FSO

    Thanks for you help Stephen but that doesn't work either.

    It will delete the files in
    Please Login or Register  to view this content.
    But doesn't touch any files of subfolders within there.

    Thanks again

  6. #6
    Forum Guru
    Join Date
    08-26-2007
    Location
    London
    Posts
    4,606

    Re: Deleting Files Using FSO

    Try adding first and last lines below:
    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)

Tags for this Thread

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