subfolder

  1. A

    VBA code to access Outlook folder sometimes don't work

    I wrote some codes in excel to extract information from a shared Outlook mailbox. But the codes sometime work sometimes don't although I didn't change anything. The error happen in line "Set InvFolder...". It can't find the subfolder. But it works sometimes. So weird Can someone help me? Thanks...
  2. A

    Macro to look thought multiple folders and subfolder for specific file name and aggregate into one File

    ello any help or direction to recourses or YouTube will be appreciated to help me in resolving below I need to aggregate multiple xls files with specific name from multiple folders and subfolder into one file. I receive multiple reports every day that are saved with in folder with Date in the...
  3. I

    Search for files that contain keywords in folder + subfolders

    Hi Everyone, Quite new to VBA and would really appreciate some help please ? I have a macro in a workbook that when ran, scans a drive that the user selects and looks for all files that contain the keyword provided. Is there anyway to: 1. Get it to scan also the subfolders within the folder...
  4. P

    Outlook Subfolder Expansion

    Hello, I've got some code that is supposed to expand some folders in Outlook. It works fine for the first level folders, but won't expand the subfolders (in this case the xx Progressions folder). The code doesn't bug out: the subfolder simply does not expand. Could anybody tell me what I've...
  5. B

    Search Folder and Sub Folders and display Information

    I found this great article (http://www.xl-central.com/list-the-files-in-a-folder-and-subfolders.html) and it is exactly what I needed. I’ve tweaked it to reflect my circumstances, my issue is, I’m trying to pull certain cell Information rather than all the information about the file itself...
  6. H

    Excel VBA GetFolder from 2 Drive (2 location)

    I had a code which work very well for 1 location (path) Possible to open and run 2 location? Sub GetFolder() Range("A:L").ClearContents Range("A1").Value = "Name" Range("B1").Value = "ParentFolder" Range("A1").Select Dim strPath As String strPath = "K:\VIEWING" 'strPath(0) =...
  7. G

    Move Mails

    Hi Everyone, Below i have a code to move all the mails to sub-folder but i am facing an error in highlighted line could any one suggest me why i am facing this error???? Option Explicit Public Sub Move_Items() Dim Inbox As Outlook.MAPIFolder Dim SubFolder As Outlook.MAPIFolder...
  8. aaaaa34

    VBA to create folder, subfolder and save workbook

    Hello my friends, I have a file mainlist.xlsx in my folder C:\Database Inside this mainlist.xlsx file, there is list of cars. in A column car brandname, B column: model name, C column model year, D column motor volume and E column price In this manner, I want to have VBA to create folder with a...
  9. N

    Count the total lines in all files in all subfolders

    i want to use vba to count all the lines in all the files in all the subfolder of a directory and display them in a cell. how do i do that? i found a code working for counting the lines in a single file. but i dont know how to construct the loop to apply this to all the files in all the...
  10. B

    Count Emails in Outlook and export to excel

    I am trying to count the amount of emails, in real time, in a subfolder in Outlook 2013 and automatically export the data to excel. I don't mind opening the excel document and refreshing the data daily, if needed. The subfolder is called "disks" - it is in a group mailbox subfolder. Any ideas?
  11. K

    Search and retrive

    Hello, I have a problem in that I have found a template with code that searches folders and sub folders for selected file types and returns the file path, date last modified etc. then in the last column it generates a link to the file, this is great for me but not for my collegues, the problem...
  12. N

    VBA - Loop through all folders and move all subfolders in each folder to a subfolder 2018

    Hi, I have large number of folders inside which I have subfolders (child folders) that I would like to move them to a new subfolder 2018 (macro should create it). In summary I need to archive all these subfolder inside each folder to a folder of last year 2018. Thanks for your help :)
  13. S

    Opening PDF from VBA

    I am trying to use the following code to open a pdf file from a folder, but I keep getting the "File not found" error. Shell "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Adobe Acrobat DC.exe " & FullPath & """, vbMinimizedFocus" Is there something I am missing? Below if the whole...
  14. sharky12345

    Get filename without extension

    I'm using this to loop through a folder and list all found files; Sub GetFolder() Range("A:L").ClearContents Range("A1").Value = "Name" Range("B1").Value = "ParentFolder" Range("C1").Value = "Size (KB)" Range("D1").Value = "DateLastModified" Range("E1").Value = "DateCreated"...
  15. B

    Iterating through folders and files with paths > 260 characters

    Hi All, As per the title, I am having an issue with iterating through folders and files where the path exceeds the charater limits. Below is my code: Sub test() Dim FileSystem As Object Dim HostFolder As String HostFolder = Sheet1.Range("F16").Value If HostFolder = "" Then MsgBox "No...
  16. K

    VBA Move files to subfolders based on filename

    Hi everyone, I am new to this forum even though I have been using it for years. My turn to ask for your help as I couldn't find a solution to my problem so far. Here is my issue: I have several files with a given name in a same folder, let's say drive D: Ex: D:\AAAA.xls D:\BBBB.xls D:\CCCC.xls...
  17. R

    VBA question - new doc in subfolder

    Hi, Do you know how to create a new word doc under the subfolder in NewR folder? This is what I have so far. I was able to create a subfolder under NewR folder, but is currently trying to create a word doc in the subfolder. Any help will be appreciated. thanks Option Explicit Private Sub...
  18. F

    List folders in directory, with criteria

    Apologies if this is a considered a duplicate post. This macro lists first and second level sub-folders after the selected folder "folderspec", with the condition that any of the subfolders' name contains the string "OK" (sub-folder with this string can be at any level). The output is divided...
  19. F

    List folders in directory, if any sub-folder contains string

    With this macro, sub-folders are listed for first and second levels (based on selected folder). The output is divided into separate columns in this example. I now want it to list folders only if any of the sub-folders contain the string "OK". The sub-folder with this string can be at any level...
  20. V

    How to transfer file in a subfolder into another subfolder inside it

    hello experts! I need your expert advise. I have a folder named Reports and inside this folder, it has multiple subfolders. I am currently doing a macro and my goal is to transfer a specific excel file (with filename "Gross Contribution Report") found inside a subfolder (example Japan) into...

This Week's Hot Topics

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top