VBA Import from Closed Workbooks: Condensing Needed

jamescooper

Well-known Member
Joined
Sep 8, 2014
Messages
840
Please help, I need to condense the below and also to ignore if the file cannot be found:

Many thanks!

Code:
Sub Forecast_AllDays()


    Dim destcell As Range, r As Long
    Dim fileSpec As String, folderPath As String, fileName As String
    
    FD = Workbooks("Model.xlsm").Worksheets("Model").Range("Z1")
        
    cellValue1 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U6")
    cellValue2 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U7")
    cellValue3 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U8")
    cellValue4 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U9")
    cellValue5 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U10")
    cellValue6 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U11")
    cellValue7 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U12")
    cellValue8 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U13")
    cellValue9 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U14")
    cellValue10 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U15")
    cellValue11 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U16")
    cellValue12 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U17")
    cellValue13 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U18")
    cellValue14 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U19")
    cellValue15 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U20")
    cellValue16 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U21")
    cellValue17 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U22")
    cellValue18 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U23")
    cellValue19 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U24")
    cellValue20 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U25")
    cellValue21 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U26")
    cellValue22 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U27")
    cellValue23 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U28")
    cellValue24 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U29")
    cellValue25 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U30")
    cellValue26 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U31")
    cellValue27 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U32")
    cellValue28 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("U33")
    
    fileSpec = FD & "Revenue\" & myValue3 & "\" & cellValue1 & ""
    fileSpec2 = FD & "Revenue\" & myValue3 & "\" & cellValue2 & ""
    fileSpec3 = FD & "Revenue\" & myValue3 & "\" & cellValue3 & ""
    fileSpec4 = FD & "Revenue\" & myValue3 & "\" & cellValue4 & ""
    fileSpec5 = FD & "Revenue\" & myValue3 & "\" & cellValue5 & ""
    fileSpec6 = FD & "Revenue\" & myValue3 & "\" & cellValue6 & ""
    fileSpec7 = FD & "Revenue\" & myValue3 & "\" & cellValue7 & ""
    fileSpec8 = FD & "Revenue\" & myValue3 & "\" & cellValue8 & ""
    fileSpec9 = FD & "Revenue\" & myValue3 & "\" & cellValue9 & ""
    fileSpec10 = FD & "Revenue\" & myValue3 & "\" & cellValue10 & ""
    fileSpec11 = FD & "Revenue\" & myValue3 & "\" & cellValue11 & ""
    fileSpec12 = FD & "Revenue\" & myValue3 & "\" & cellValue12 & ""
    fileSpec13 = FD & "Revenue\" & myValue3 & "\" & cellValue13 & ""
    fileSpec14 = FD & "Revenue\" & myValue3 & "\" & cellValue14 & ""
    fileSpec15 = FD & "Revenue\" & myValue3 & "\" & cellValue15 & ""
    fileSpec16 = FD & "Revenue\" & myValue3 & "\" & cellValue16 & ""
    fileSpec17 = FD & "Revenue\" & myValue3 & "\" & cellValue17 & ""
    fileSpec18 = FD & "Revenue\" & myValue3 & "\" & cellValue18 & ""
    fileSpec19 = FD & "Revenue\" & myValue3 & "\" & cellValue19 & ""
    fileSpec20 = FD & "Revenue\" & myValue3 & "\" & cellValue20 & ""
    fileSpec21 = FD & "Revenue\" & myValue3 & "\" & cellValue21 & ""
    fileSpec22 = FD & "Revenue\" & myValue3 & "\" & cellValue22 & ""
    fileSpec23 = FD & "Revenue\" & myValue3 & "\" & cellValue23 & ""
    fileSpec24 = FD & "Revenue\" & myValue3 & "\" & cellValue24 & ""
    fileSpec25 = FD & "Revenue\" & myValue3 & "\" & cellValue25 & ""
    fileSpec26 = FD & "Revenue\" & myValue3 & "\" & cellValue26 & ""
    fileSpec27 = FD & "Revenue\" & myValue3 & "\" & cellValue27 & ""
    fileSpec28 = FD & "Revenue\" & myValue3 & "\" & cellValue28 & ""
    
    Set destcell1 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C6")
    Set destcell2 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D6")
    Set destcell3 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E6")
    Set destcell4 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F6")
    Set destcell5 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G6")
    Set destcell6 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H6")
    Set destcell7 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I6")
    Set destcell8 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J6")
    Set destcell9 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K6")
    Set destcell10 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L6")
    Set destcell11 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M6")
    Set destcell12 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N6")
    Set destcell13 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C7")
    Set destcell14 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D7")
    Set destcell15 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E7")
    Set destcell16 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F7")
    Set destcell17 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G7")
    Set destcell18 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H7")
    Set destcell19 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I7")
    Set destcell20 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J7")
    Set destcell21 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K7")
    Set destcell22 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L7")
    Set destcell23 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M7")
    Set destcell24 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N7")
    Set destcell25 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C8")
    Set destcell26 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D8")
    Set destcell27 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E8")
    Set destcell28 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F8")
    Set destcell29 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G8")
    Set destcell30 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H8")
    Set destcell31 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I8")
    Set destcell32 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J8")
    Set destcell33 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K8")
    Set destcell34 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L8")
    Set destcell35 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M8")
    Set destcell36 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N8")
    Set destcell37 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C9")
    Set destcell38 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D9")
    Set destcell39 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E9")
    Set destcell40 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F9")
    Set destcell41 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G9")
    Set destcell42 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H9")
    Set destcell43 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I9")
    Set destcell44 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J9")
    Set destcell45 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K9")
    Set destcell46 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L9")
    Set destcell47 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M9")
    Set destcell48 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N9")
    Set destcell49 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C10")
    Set destcell50 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D10")
    Set destcell51 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E10")
    Set destcell52 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F10")
    Set destcell53 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G10")
    Set destcell54 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H10")
    Set destcell55 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I10")
    Set destcell56 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J10")
    Set destcell57 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K10")
    Set destcell58 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L10")
    Set destcell59 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M10")
    Set destcell60 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N10")
    Set destcell61 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C11")
    Set destcell62 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D11")
    Set destcell63 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E11")
    Set destcell64 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F11")
    Set destcell65 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G11")
    Set destcell66 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H11")
    Set destcell67 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I11")
    Set destcell68 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J11")
    Set destcell69 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K11")
    Set destcell70 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L11")
    Set destcell71 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M11")
    Set destcell72 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N11")
    Set destcell73 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C12")
    Set destcell74 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D12")
    Set destcell75 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E12")
    Set destcell76 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F12")
    Set destcell77 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G12")
    Set destcell78 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H12")
    Set destcell79 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I12")
    Set destcell80 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J12")
    Set destcell81 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K12")
    Set destcell82 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L12")
    Set destcell83 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M12")
    Set destcell84 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N12")
    Set destcell85 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C13")
    Set destcell86 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D13")
    Set destcell87 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E13")
    Set destcell88 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F13")
    Set destcell89 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G13")
    Set destcell90 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H13")
    Set destcell91 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I13")
    Set destcell92 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J13")
    Set destcell93 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K13")
    Set destcell94 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L13")
    Set destcell95 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M13")
    Set destcell96 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N13")
    Set destcell97 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C14")
    Set destcell98 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D14")
    Set destcell99 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E14")
    Set destcell100 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F14")
    Set destcell101 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G14")
    Set destcell102 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H14")
    Set destcell103 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I14")
    Set destcell104 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J14")
    Set destcell105 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K14")
    Set destcell106 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L14")
    Set destcell107 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M14")
    Set destcell108 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N14")
    Set destcell109 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C15")
    Set destcell110 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D15")
    Set destcell111 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E15")
    Set destcell112 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F15")
    Set destcell113 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G15")
    Set destcell114 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H15")
    Set destcell115 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I15")
    Set destcell116 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J15")
    Set destcell117 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K15")
    Set destcell118 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L15")
    Set destcell119 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M15")
    Set destcell120 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N15")
    Set destcell121 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C16")
    Set destcell122 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D16")
    Set destcell123 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E16")
    Set destcell124 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F16")
    Set destcell125 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G16")
    Set destcell126 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H16")
    Set destcell127 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I16")
    Set destcell128 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J16")
    Set destcell129 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K16")
    Set destcell130 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L16")
    Set destcell131 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M16")
    Set destcell132 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N16")
    Set destcell133 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C17")
    Set destcell134 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D17")
    Set destcell135 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E17")
    Set destcell136 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F17")
    Set destcell137 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G17")
    Set destcell138 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H17")
    Set destcell139 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I17")
    Set destcell140 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J17")
    Set destcell141 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K17")
    Set destcell142 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L17")
    Set destcell143 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M17")
    Set destcell144 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N17")
    Set destcell145 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C18")
    Set destcell146 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D18")
    Set destcell147 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E18")
    Set destcell148 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F18")
    Set destcell149 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G18")
    Set destcell150 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H18")
    Set destcell151 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I18")
    Set destcell152 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J18")
    Set destcell153 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K18")
    Set destcell154 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L18")
    Set destcell155 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M18")
    Set destcell156 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N18")
    Set destcell157 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C19")
    Set destcell158 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D19")
    Set destcell159 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E19")
    Set destcell160 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F19")
    Set destcell161 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G19")
    Set destcell162 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H19")
    Set destcell163 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I19")
    Set destcell164 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J19")
    Set destcell165 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K19")
    Set destcell166 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L19")
    Set destcell167 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M19")
    Set destcell168 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N19")
    Set destcell169 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C20")
    Set destcell170 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D20")
    Set destcell171 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E20")
    Set destcell172 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F20")
    Set destcell173 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G20")
    Set destcell174 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H20")
    Set destcell175 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I20")
    Set destcell176 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J20")
    Set destcell177 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K20")
    Set destcell178 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L20")
    Set destcell179 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M20")
    Set destcell180 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N20")
    Set destcell181 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C21")
    Set destcell182 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D21")
    Set destcell183 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E21")
    Set destcell184 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F21")
    Set destcell185 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G21")
    Set destcell186 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H21")
    Set destcell187 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I21")
    Set destcell188 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J21")
    Set destcell189 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K21")
    Set destcell190 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L21")
    Set destcell191 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M21")
    Set destcell192 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N21")
    Set destcell193 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C22")
    Set destcell194 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D22")
    Set destcell195 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E22")
    Set destcell196 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F22")
    Set destcell197 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G22")
    Set destcell198 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H22")
    Set destcell199 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I22")
    Set destcell200 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J22")
    Set destcell201 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K22")
    Set destcell202 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L22")
    Set destcell203 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M22")
    Set destcell204 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N22")
    Set destcell205 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C23")
    Set destcell206 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D23")
    Set destcell207 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E23")
    Set destcell208 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F23")
    Set destcell209 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G23")
    Set destcell210 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H23")
    Set destcell211 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I23")
    Set destcell212 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J23")
    Set destcell213 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K23")
    Set destcell214 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L23")
    Set destcell215 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M23")
    Set destcell216 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N23")
    Set destcell217 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C24")
    Set destcell218 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D24")
    Set destcell219 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E24")
    Set destcell220 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F24")
    Set destcell221 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G24")
    Set destcell222 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H24")
    Set destcell223 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I24")
    Set destcell224 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J24")
    Set destcell225 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K24")
    Set destcell226 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L24")
    Set destcell227 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M24")
    Set destcell228 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N24")
    Set destcell229 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C25")
    Set destcell230 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D25")
    Set destcell231 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E25")
    Set destcell232 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F25")
    Set destcell233 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G25")
    Set destcell234 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H25")
    Set destcell235 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I25")
    Set destcell236 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J25")
    Set destcell237 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K25")
    Set destcell238 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L25")
    Set destcell239 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M25")
    Set destcell240 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N25")
    Set destcell241 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C26")
    Set destcell242 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D26")
    Set destcell243 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E26")
    Set destcell244 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F26")
    Set destcell245 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G26")
    Set destcell246 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H26")
    Set destcell247 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I26")
    Set destcell248 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J26")
    Set destcell249 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K26")
    Set destcell250 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L26")
    Set destcell251 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M26")
    Set destcell252 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N26")
    Set destcell253 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C27")
    Set destcell254 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D27")
    Set destcell255 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E27")
    Set destcell256 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F27")
    Set destcell257 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G27")
    Set destcell258 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H27")
    Set destcell259 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I27")
    Set destcell260 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J27")
    Set destcell261 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K27")
    Set destcell262 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L27")
    Set destcell263 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M27")
    Set destcell264 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N27")
    Set destcell265 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C28")
    Set destcell266 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D28")
    Set destcell267 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E28")
    Set destcell268 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F28")
    Set destcell269 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G28")
    Set destcell270 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H28")
    Set destcell271 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I28")
    Set destcell272 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J28")
    Set destcell273 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K28")
    Set destcell274 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L28")
    Set destcell275 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M28")
    Set destcell276 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N28")
    Set destcell277 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C29")
    Set destcell278 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D29")
    Set destcell279 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E29")
    Set destcell280 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F29")
    Set destcell281 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G29")
    Set destcell282 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H29")
    Set destcell283 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I29")
    Set destcell284 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J29")
    Set destcell285 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K29")
    Set destcell286 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L29")
    Set destcell287 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M29")
    Set destcell288 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N29")
    Set destcell289 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C30")
    Set destcell290 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D30")
    Set destcell291 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E30")
    Set destcell292 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F30")
    Set destcell293 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G30")
    Set destcell294 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H30")
    Set destcell295 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I30")
    Set destcell296 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J30")
    Set destcell297 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K30")
    Set destcell298 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L30")
    Set destcell299 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M30")
    Set destcell300 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N30")
    Set destcell301 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C31")
    Set destcell302 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D31")
    Set destcell303 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E31")
    Set destcell304 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F31")
    Set destcell305 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G31")
    Set destcell306 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H31")
    Set destcell307 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I31")
    Set destcell308 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J31")
    Set destcell309 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K31")
    Set destcell310 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L31")
    Set destcell311 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M31")
    Set destcell312 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N31")
    Set destcell313 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C32")
    Set destcell314 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D32")
    Set destcell315 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E32")
    Set destcell316 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F32")
    Set destcell317 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G32")
    Set destcell318 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H32")
    Set destcell319 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I32")
    Set destcell320 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J32")
    Set destcell321 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K32")
    Set destcell322 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L32")
    Set destcell323 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M32")
    Set destcell324 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N32")
    Set destcell325 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("C33")
    Set destcell326 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("D33")
    Set destcell327 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("E33")
    Set destcell328 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("F33")
    Set destcell329 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("G33")
    Set destcell330 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("H33")
    Set destcell331 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("I33")
    Set destcell332 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("J33")
    Set destcell333 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("K33")
    Set destcell334 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("L33")
    Set destcell335 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("M33")
    Set destcell336 = Workbooks("Forecast Template.xlsx").Sheets("Revenue").Range("N33")
   
    r = 0
    
    folderPath = Left(fileSpec, InStrRev(fileSpec, "\"))
    folderPath2 = Left(fileSpec, InStrRev(fileSpec2, "\"))
    folderPath3 = Left(fileSpec, InStrRev(fileSpec3, "\"))
    folderPath4 = Left(fileSpec, InStrRev(fileSpec4, "\"))
    folderPath5 = Left(fileSpec, InStrRev(fileSpec5, "\"))
    folderPath6 = Left(fileSpec, InStrRev(fileSpec6, "\"))
    folderPath7 = Left(fileSpec, InStrRev(fileSpec7, "\"))
    folderPath8 = Left(fileSpec, InStrRev(fileSpec8, "\"))
    folderPath9 = Left(fileSpec, InStrRev(fileSpec9, "\"))
    folderPath10 = Left(fileSpec, InStrRev(fileSpec10, "\"))
    folderPath11 = Left(fileSpec, InStrRev(fileSpec11, "\"))
    folderPath12 = Left(fileSpec, InStrRev(fileSpec12, "\"))
    folderPath13 = Left(fileSpec, InStrRev(fileSpec13, "\"))
    folderPath14 = Left(fileSpec, InStrRev(fileSpec14, "\"))
    folderPath15 = Left(fileSpec, InStrRev(fileSpec15, "\"))
    folderPath16 = Left(fileSpec, InStrRev(fileSpec16, "\"))
    folderPath17 = Left(fileSpec, InStrRev(fileSpec17, "\"))
    folderPath18 = Left(fileSpec, InStrRev(fileSpec18, "\"))
    folderPath19 = Left(fileSpec, InStrRev(fileSpec19, "\"))
    folderPath20 = Left(fileSpec, InStrRev(fileSpec20, "\"))
    folderPath21 = Left(fileSpec, InStrRev(fileSpec21, "\"))
    folderPath22 = Left(fileSpec, InStrRev(fileSpec22, "\"))
    folderPath23 = Left(fileSpec, InStrRev(fileSpec23, "\"))
    folderPath24 = Left(fileSpec, InStrRev(fileSpec24, "\"))
    folderPath25 = Left(fileSpec, InStrRev(fileSpec25, "\"))
    folderPath26 = Left(fileSpec, InStrRev(fileSpec26, "\"))
    folderPath27 = Left(fileSpec, InStrRev(fileSpec27, "\"))
    folderPath28 = Left(fileSpec, InStrRev(fileSpec28, "\"))


    fileName = Dir(fileSpec)
    fileName2 = Dir(fileSpec2)
    fileName3 = Dir(fileSpec3)
    fileName4 = Dir(fileSpec4)
    fileName5 = Dir(fileSpec5)
    fileName6 = Dir(fileSpec6)
    fileName7 = Dir(fileSpec7)
    fileName8 = Dir(fileSpec8)
    fileName9 = Dir(fileSpec9)
    fileName10 = Dir(fileSpec10)
    fileName11 = Dir(fileSpec11)
    fileName12 = Dir(fileSpec12)
    fileName13 = Dir(fileSpec13)
    fileName14 = Dir(fileSpec14)
    fileName15 = Dir(fileSpec15)
    fileName16 = Dir(fileSpec16)
    fileName17 = Dir(fileSpec17)
    fileName18 = Dir(fileSpec18)
    fileName19 = Dir(fileSpec19)
    fileName20 = Dir(fileSpec20)
    fileName21 = Dir(fileSpec21)
    fileName22 = Dir(fileSpec22)
    fileName23 = Dir(fileSpec23)
    fileName24 = Dir(fileSpec24)
    fileName25 = Dir(fileSpec25)
    fileName26 = Dir(fileSpec26)
    fileName27 = Dir(fileSpec27)
    fileName28 = Dir(fileSpec28)
            
    While Len(fileName) <> 0
    
destcell1.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H12")
destcell2.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H20")
destcell3.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H28")
destcell4.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H37")
destcell5.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H48")
destcell6.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H55")
destcell7.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H64")
destcell8.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H72")
destcell9.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H80")
destcell10.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H87")
destcell11.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H96")
destcell12.Offset(r, 0).Value = GetCellValue(folderPath & fileName, "Forecast", "H105")
destcell13.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F12")
destcell14.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F20")
destcell15.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F28")
destcell16.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F37")
destcell17.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F48")
destcell18.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F55")
destcell19.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F64")
destcell20.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F72")
destcell21.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F80")
destcell22.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F87")
destcell23.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F96")
destcell24.Offset(r, 0).Value = GetCellValue(folderPath1 & fileName1, "Forecast", "F105")
destcell25.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F12")
destcell26.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F20")
destcell27.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F28")
destcell28.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F37")
destcell29.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F48")
destcell30.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F55")
destcell31.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F64")
destcell32.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F72")
destcell33.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F80")
destcell34.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F87")
destcell35.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F96")
destcell36.Offset(r, 0).Value = GetCellValue(folderPath2 & fileName2, "Forecast", "F105")
destcell37.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F12")
destcell38.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F20")
destcell39.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F28")
destcell40.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F37")
destcell41.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F48")
destcell42.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F55")
destcell43.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F64")
destcell44.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F72")
destcell45.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F80")
destcell46.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F87")
destcell47.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F96")
destcell48.Offset(r, 0).Value = GetCellValue(folderPath3 & fileName3, "Forecast", "F105")
destcell49.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F12")
destcell50.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F20")
destcell51.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F28")
destcell52.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F37")
destcell53.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F48")
destcell54.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F55")
destcell55.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F64")
destcell56.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F72")
destcell57.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F80")
destcell58.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F87")
destcell59.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F96")
destcell60.Offset(r, 0).Value = GetCellValue(folderPath4 & fileName4, "Forecast", "F105")
destcell61.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F12")
destcell62.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F20")
destcell63.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F28")
destcell64.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F37")
destcell65.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F48")
destcell66.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F55")
destcell67.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F64")
destcell68.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F72")
destcell69.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F80")
destcell70.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F87")
destcell71.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F96")
destcell72.Offset(r, 0).Value = GetCellValue(folderPath5 & fileName5, "Forecast", "F105")
destcell73.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G12")
destcell74.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G20")
destcell75.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G28")
destcell76.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G37")
destcell77.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G48")
destcell78.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G55")
destcell79.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G64")
destcell80.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G72")
destcell81.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G80")
destcell82.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G87")
destcell83.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G96")
destcell84.Offset(r, 0).Value = GetCellValue(folderPath6 & fileName6, "Forecast", "G105")
destcell85.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H12")
destcell86.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H20")
destcell87.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H28")
destcell88.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H37")
destcell89.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H48")
destcell90.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H55")
destcell91.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H64")
destcell92.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H72")
destcell93.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H80")
destcell94.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H87")
destcell95.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H96")
destcell96.Offset(r, 0).Value = GetCellValue(folderPath7 & fileName7, "Forecast", "H105")
destcell97.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F12")
destcell98.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F20")
destcell99.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F28")
destcell100.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F37")
destcell101.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F48")
destcell102.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F55")
destcell103.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F64")
destcell104.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F72")
destcell105.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F80")
destcell106.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F87")
destcell107.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F96")
destcell108.Offset(r, 0).Value = GetCellValue(folderPath8 & fileName8, "Forecast", "F105")
destcell109.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F12")
destcell110.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F20")
destcell111.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F28")
destcell112.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F37")
destcell113.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F48")
destcell114.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F55")
destcell115.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F64")
destcell116.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F72")
destcell117.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F80")
destcell118.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F87")
destcell119.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F96")
destcell120.Offset(r, 0).Value = GetCellValue(folderPath9 & fileName9, "Forecast", "F105")
destcell121.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F12")
destcell122.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F20")
destcell123.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F28")
destcell124.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F37")
destcell125.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F48")
destcell126.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F55")
destcell127.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F64")
destcell128.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F72")
destcell129.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F80")
destcell130.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F87")
destcell131.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F96")
destcell132.Offset(r, 0).Value = GetCellValue(folderPath10 & fileName10, "Forecast", "F105")
destcell133.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F12")
destcell134.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F20")
destcell135.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F28")
destcell136.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F37")
destcell137.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F48")
destcell138.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F55")
destcell139.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F64")
destcell140.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F72")
destcell141.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F80")
destcell142.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F87")
destcell143.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F96")
destcell144.Offset(r, 0).Value = GetCellValue(folderPath11 & fileName11, "Forecast", "F105")
destcell145.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F12")
destcell146.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F20")
destcell147.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F28")
destcell148.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F37")
destcell149.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F48")
destcell150.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F55")
destcell151.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F64")
destcell152.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F72")
destcell153.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F80")
destcell154.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F87")
destcell155.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F96")
destcell156.Offset(r, 0).Value = GetCellValue(folderPath12 & fileName12, "Forecast", "F105")
destcell157.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G12")
destcell158.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G20")
destcell159.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G28")
destcell160.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G37")
destcell161.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G48")
destcell162.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G55")
destcell163.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G64")
destcell164.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G72")
destcell165.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G80")
destcell166.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G87")
destcell167.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G96")
destcell168.Offset(r, 0).Value = GetCellValue(folderPath13 & fileName13, "Forecast", "G105")
destcell169.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H12")
destcell170.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H20")
destcell171.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H28")
destcell172.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H37")
destcell173.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H48")
destcell174.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H55")
destcell175.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H64")
destcell176.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H72")
destcell177.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H80")
destcell178.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H87")
destcell179.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H96")
destcell180.Offset(r, 0).Value = GetCellValue(folderPath14 & fileName14, "Forecast", "H105")
destcell181.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F12")
destcell182.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F20")
destcell183.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F28")
destcell184.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F37")
destcell185.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F48")
destcell186.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F55")
destcell187.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F64")
destcell188.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F72")
destcell189.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F80")
destcell190.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F87")
destcell191.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F96")
destcell192.Offset(r, 0).Value = GetCellValue(folderPath15 & fileName15, "Forecast", "F105")
destcell193.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F12")
destcell194.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F20")
destcell195.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F28")
destcell196.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F37")
destcell197.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F48")
destcell198.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F55")
destcell199.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F64")
destcell200.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F72")
destcell201.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F80")
destcell202.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F87")
destcell203.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F96")
destcell204.Offset(r, 0).Value = GetCellValue(folderPath16 & fileName16, "Forecast", "F105")
destcell205.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F12")
destcell206.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F20")
destcell207.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F28")
destcell208.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F37")
destcell209.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F48")
destcell210.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F55")
destcell211.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F64")
destcell212.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F72")
destcell213.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F80")
destcell214.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F87")
destcell215.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F96")
destcell216.Offset(r, 0).Value = GetCellValue(folderPath17 & fileName17, "Forecast", "F105")
destcell217.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F12")
destcell218.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F20")
destcell219.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F28")
destcell220.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F37")
destcell221.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F48")
destcell222.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F55")
destcell223.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F64")
destcell224.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F72")
destcell225.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F80")
destcell226.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F87")
destcell227.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F96")
destcell228.Offset(r, 0).Value = GetCellValue(folderPath18 & fileName18, "Forecast", "F105")
destcell229.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F12")
destcell230.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F20")
destcell231.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F28")
destcell232.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F37")
destcell233.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F48")
destcell234.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F55")
destcell235.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F64")
destcell236.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F72")
destcell237.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F80")
destcell238.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F87")
destcell239.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F96")
destcell240.Offset(r, 0).Value = GetCellValue(folderPath19 & fileName19, "Forecast", "F105")
destcell241.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G12")
destcell242.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G20")
destcell243.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G28")
destcell244.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G37")
destcell245.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G48")
destcell246.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G55")
destcell247.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G64")
destcell248.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G72")
destcell249.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G80")
destcell250.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G87")
destcell251.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G96")
destcell252.Offset(r, 0).Value = GetCellValue(folderPath20 & fileName20, "Forecast", "G105")
destcell253.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H12")
destcell254.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H20")
destcell255.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H28")
destcell256.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H37")
destcell257.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H48")
destcell258.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H55")
destcell259.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H64")
destcell260.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H72")
destcell261.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H80")
destcell262.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H87")
destcell263.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H96")
destcell264.Offset(r, 0).Value = GetCellValue(folderPath21 & fileName21, "Forecast", "H105")
destcell265.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F12")
destcell266.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F20")
destcell267.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F28")
destcell268.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F37")
destcell269.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F48")
destcell270.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F55")
destcell271.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F64")
destcell272.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F72")
destcell273.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F80")
destcell274.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F87")
destcell275.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F96")
destcell276.Offset(r, 0).Value = GetCellValue(folderPath22 & fileName22, "Forecast", "F105")
destcell277.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F12")
destcell278.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F20")
destcell279.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F28")
destcell280.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F37")
destcell281.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F48")
destcell282.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F55")
destcell283.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F64")
destcell284.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F72")
destcell285.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F80")
destcell286.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F87")
destcell287.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F96")
destcell288.Offset(r, 0).Value = GetCellValue(folderPath23 & fileName23, "Forecast", "F105")
destcell289.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F12")
destcell290.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F20")
destcell291.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F28")
destcell292.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F37")
destcell293.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F48")
destcell294.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F55")
destcell295.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F64")
destcell296.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F72")
destcell297.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F80")
destcell298.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F87")
destcell299.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F96")
destcell300.Offset(r, 0).Value = GetCellValue(folderPath24 & fileName24, "Forecast", "F105")
destcell301.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F12")
destcell302.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F20")
destcell303.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F28")
destcell304.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F37")
destcell305.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F48")
destcell306.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F55")
destcell307.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F64")
destcell308.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F72")
destcell309.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F80")
destcell310.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F87")
destcell311.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F96")
destcell312.Offset(r, 0).Value = GetCellValue(folderPath25 & fileName25, "Forecast", "F105")
destcell313.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F12")
destcell314.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F20")
destcell315.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F28")
destcell316.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F37")
destcell317.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F48")
destcell318.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F55")
destcell319.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F64")
destcell320.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F72")
destcell321.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F80")
destcell322.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F87")
destcell323.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F96")
destcell324.Offset(r, 0).Value = GetCellValue(folderPath26 & fileName26, "Forecast", "F105")
destcell325.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G12")
destcell326.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G20")
destcell327.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G28")
destcell328.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G37")
destcell329.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G48")
destcell330.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G55")
destcell331.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G64")
destcell332.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G72")
destcell333.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G80")
destcell334.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G87")
destcell335.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G96")
destcell336.Offset(r, 0).Value = GetCellValue(folderPath27 & fileName27, "Forecast", "G105")
    
        r = r + 1
        fileName = Dir
    Wend
      
End Sub


Private Function GetCellValue(ByVal workbookFullName As String, sheetName As String, cellsRange As String)


    Dim folderPath As String, fileName As String
    Dim arg As String
    
    folderPath = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath2 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName2 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath3 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName3 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath4 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName4 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath5 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName5 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath6 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName6 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath7 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName7 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath8 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName8 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath9 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName9 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath10 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName10 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath11 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName11 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath12 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName12 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath13 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName13 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath14 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName14 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath15 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName15 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath16 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName16 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath17 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName17 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath18 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName18 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath19 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName19 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath20 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName20 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath21 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName21 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath22 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName22 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath23 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName23 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath24 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName24 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath25 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName25 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath26 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName26 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath27 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName27 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
    folderPath28 = Left(workbookFullName, InStrRev(workbookFullName, "\"))
    fileName28 = Mid(workbookFullName, InStrRev(workbookFullName, "\") + 1)
      
    arg = "'" & folderPath & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath2 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath3 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath4 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath5 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath6 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath7 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath8 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath9 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath10 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath11 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath12 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath13 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath14 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath15 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath16 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath17 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath18 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath19 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath20 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath21 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath22 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath23 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath24 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath25 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath26 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath27 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    arg = "'" & folderPath28 & "[" & fileName & "]" & sheetName & "'!" & Range(cellsRange).Address(True, True, xlR1C1)
    
    Debug.Print arg
             
    GetCellValue = ExecuteExcel4Macro(arg)
    
End Function
 

Excel Facts

Excel motto
Not everything I do at work revolves around Excel. Only the fun parts.

Forum statistics

Threads
1,224,823
Messages
6,181,175
Members
453,021
Latest member
Justyna P

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