I wrote the code below to download data from 100 *.csv files, copy and paste one line of data from each into a spreadsheet (spreadsheet attached). The code runs sometimes, but other times Excel goes into 'not responding' and it just hangs. I tried to divide up the processing burden into multiple modules, each with identical code but just a shorter piece of the total loop (now 6 modules), but it still occasionally hangs up. When it freezes the debugger highlights this line ' .Refresh BackgroundQuery:=False', so this could be the culprit. Does anyone have any ideas? Perhaps I've structured the module incorrectly... or missed something basic. Thanks so much!
Bookmarks