workbook loop

FROGGER24

Well-known Member
Joined
May 22, 2004
Messages
704
Office Version
  1. 2013
  2. 2010
Platform
  1. Windows
I have a workbook called PAR.xls that I need to go to this directory and gather information from multiple cells. The folder name will always be different since it will be based on month/year. I will need the enduser to select the proper month/year to run the code on.
\na.aaa.com\dfs\bbb\ccc\ddd\VPR\eee2011\eeee 03 - 2011
Once inside the folder I will need this code to run on the worksheet called "Times" which is gathering all the data into one row so that it will import into PAR workbook. sheet1!.

Range("A70") = Range("B9").Value
Range("B70") = Range("B10").Value
Range("C70") = Range("C16").Value
Range("D70") = Range("C20").Value
Range("E70") = Range("C35").Value
Range("F70") = Range("C36").Value
Range("G70") = Range("C37").Value
Range("H70") = Range("H15").Value
Range("I70") = Range("H16").Value
Range("J70") = Range("H17").Value
Range("K70") = Range("H18").Value
Range("L70") = Range("H20").Value
Range("M70") = Range("H22").Value
Range("N70") = Range("H23").Value
Range("O70") = Range("H26").Value
Range("P70") = Range("H29").Value
Range("Q70") = Range("H30").Value
Range("R70") = Range("H31").Value
Range("S70") = Range("H33").Value
Range("T70") = Range("A47").Value
Range("U70") = Range("A48").Value
Range("V70") = Range("A49").Value
Range("W70") = Range("A50").Value
Range("X70") = Range("A51").Value
Range("Y70") = Range("A52").Value
Range("Z70") = Range("A53").Value
Range("AA70") = Range("A54").Value
Range("AB70") = Range("A55").Value
Range("A70:AB70").Copy
 

Excel Facts

Ambidextrous Undo
Undo last command with Ctrl+Z or Alt+Backspace. If you use the Undo icon in the QAT, open the drop-down arrow to undo up to 100 steps.

Forum statistics

Threads
1,224,507
Messages
6,179,181
Members
452,893
Latest member
denay

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
Back
Top