Help Simplifying this Macro

Nathan B

New Member
Joined
Apr 18, 2002
Messages
35
Can anyone help shorten this macro?

Dim i As String
i = "G"
On Error Resume Next
Application.EnableEvents = False
Application.ScreenUpdating = False
Workbooks.Open FileName:="J:\FMLA\9FMLA.XLS", password:="572"
Windows("FMLAMaster.xls").Activate
Sheets("Plant 9").Select
Range("B6").Select

If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(6, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(14, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r14c3"
Range("C6").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r14c4"
Sheets("calc").Select
Range(i + "1") = False
Range(i + "101") = False
Range(i + "201") = False
End If

Sheets("Plant 9").Select
Range("B7").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(7, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(15, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r15c3"
Range("C7").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r15c4"
Sheets("calc").Select
Range(i + "2") = False
Range(i + "102") = False
Range(i + "202") = False
End If

Sheets("Plant 9").Select
Range("B8").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(8, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(16, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r16c3"
Range("C8").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r16c4"
Sheets("calc").Select
Range(i + "3") = False
Range(i + "103") = False
Range(i + "203") = False
End If

Sheets("Plant 9").Select
Range("B9").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(9, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(17, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r17c3"
Range("C9").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r17c4"
Sheets("calc").Select
Range(i + "4") = False
Range(i + "104") = False
Range(i + "204") = False
End If

Sheets("Plant 9").Select
Range("B10").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(10, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(18, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r18c3"
Range("C10").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r18c4"
Sheets("calc").Select
Range(i + "5") = False
Range(i + "105") = False
Range(i + "205") = False
End If

Sheets("Plant 9").Select
Range("B11").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(11, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(19, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r19c3"
Range("C11").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r19c4"
Sheets("calc").Select
Range(i + "6") = False
Range(i + "106") = False
Range(i + "206") = False
End If

Sheets("Plant 9").Select
Range("B12").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(12, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(20, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r20c3"
Range("C12").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r20c4"
Sheets("calc").Select
Range(i + "7") = False
Range(i + "107") = False
Range(i + "207") = False
End If

Sheets("Plant 9").Select
Range("B13").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(13, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(21, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r21c3"
Range("C13").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r21c4"
Sheets("calc").Select
Range(i + "8") = False
Range(i + "108") = False
Range(i + "208") = False
End If

Sheets("Plant 9").Select
Range("B14").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(14, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(22, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r22c3"
Range("C14").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r22c4"
Sheets("calc").Select
Range(i + "9") = False
Range(i + "109") = False
Range(i + "209") = False
End If

Sheets("Plant 9").Select
Range("B15").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(15, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(23, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r23c3"
Range("C15").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r23c4"
Sheets("calc").Select
Range(i + "10") = False
Range(i + "110") = False
Range(i + "210") = False
End If

Sheets("Plant 9").Select
Range("B16").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(16, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(24, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r24c3"
Range("C16").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r24c4"
Sheets("calc").Select
Range(i + "11") = False
Range(i + "111") = False
Range(i + "211") = False
End If

Sheets("Plant 9").Select
Range("B17").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(17, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(25, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r25c3"
Range("C17").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r25c4"
Sheets("calc").Select
Range(i + "12") = False
Range(i + "112") = False
Range(i + "212") = False
End If

Sheets("Plant 9").Select
Range("B18").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(18, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(26, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r26c3"
Range("C18").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r26c4"
Sheets("calc").Select
Range(i + "13") = False
Range(i + "113") = False
Range(i + "213") = False
End If

Sheets("Plant 9").Select
Range("B19").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(19, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(27, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r27c3"
Range("C19").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r27c4"
Sheets("calc").Select
Range(i + "14") = False
Range(i + "114") = False
Range(i + "214") = False
End If

Sheets("Plant 9").Select
Range("B20").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(20, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(28, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r28c3"
Range("C20").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r28c4"
Sheets("calc").Select
Range(i + "15") = False
Range(i + "115") = False
Range(i + "215") = False
End If

Sheets("Plant 9").Select
Range("B21").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(21, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(29, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r29c3"
Range("C21").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r29c4"
Sheets("calc").Select
Range(i + "16") = False
Range(i + "116") = False
Range(i + "216") = False
End If

Sheets("Plant 9").Select
Range("B22").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(22, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(30, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r30c3"
Range("C22").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r30c4"
Sheets("calc").Select
Range(i + "17") = False
Range(i + "117") = False
Range(i + "217") = False
End If

Sheets("Plant 9").Select
Range("B23").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(23, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(31, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r31c3"
Range("C23").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r31c4"
Sheets("calc").Select
Range(i + "18") = False
Range(i + "118") = False
Range(i + "218") = False
End If

Sheets("Plant 9").Select
Range("B24").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(24, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(32, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r32c3"
Range("C24").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r32c4"
Sheets("calc").Select
Range(i + "19") = False
Range(i + "119") = False
Range(i + "219") = False
End If

Sheets("Plant 9").Select
Range("B25").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(25, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(33, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r33c3"
Range("C25").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r33c4"
Sheets("calc").Select
Range(i + "20") = False
Range(i + "120") = False
Range(i + "220") = False
End If

Sheets("Plant 9").Select
Range("B26").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(26, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(34, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r34c3"
Range("C26").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r34c4"
Sheets("calc").Select
Range(i + "21") = False
Range(i + "121") = False
Range(i + "221") = False
End If

Sheets("Plant 9").Select
Range("B27").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(27, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(35, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r35c3"
Range("C27").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r35c4"
Sheets("calc").Select
Range(i + "22") = False
Range(i + "122") = False
Range(i + "222") = False
End If

Sheets("Plant 9").Select
Range("B28").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(28, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(36, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r36c3"
Range("C28").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r36c4"
Sheets("calc").Select
Range(i + "23") = False
Range(i + "123") = False
Range(i + "223") = False
End If

Sheets("Plant 9").Select
Range("B29").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(29, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(37, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r37c3"
Range("C29").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r37c4"
Sheets("calc").Select
Range(i + "24") = False
Range(i + "124") = False
Range(i + "224") = False
End If

Sheets("Plant 9").Select
Range("B30").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(30, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(38, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r38c3"
Range("C30").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r38c4"
Sheets("calc").Select
Range(i + "25") = False
Range(i + "125") = False
Range(i + "225") = False
End If

Sheets("Plant 9").Select
Range("B31").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(31, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(39, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r39c3"
Range("C31").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r39c4"
Sheets("calc").Select
Range(i + "26") = False
Range(i + "126") = False
Range(i + "226") = False
End If

Sheets("Plant 9").Select
Range("B32").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(32, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(40, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r40c3"
Range("C32").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r40c4"
Sheets("calc").Select
Range(i + "27") = False
Range(i + "127") = False
Range(i + "227") = False
End If

Sheets("Plant 9").Select
Range("B33").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(33, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(41, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r41c3"
Range("C33").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r41c4"
Sheets("calc").Select
Range(i + "28") = False
Range(i + "128") = False
Range(i + "228") = False
End If

Sheets("Plant 9").Select
Range("B34").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(34, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(42, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r42c3"
Range("C34").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r42c4"
Sheets("calc").Select
Range(i + "29") = False
Range(i + "129") = False
Range(i + "229") = False
End If

Sheets("Plant 9").Select
Range("B35").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(35, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(43, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r43c3"
Range("C35").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r43c4"
Sheets("calc").Select
Range(i + "30") = False
Range(i + "130") = False
Range(i + "230") = False
End If

Sheets("Plant 9").Select
Range("B36").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(36, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(44, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r44c3"
Range("C36").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r44c4"
Sheets("calc").Select
Range(i + "31") = False
Range(i + "131") = False
Range(i + "231") = False
End If

Sheets("Plant 9").Select
Range("B37").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(37, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(45, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r45c3"
Range("C37").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r45c4"
Sheets("calc").Select
Range(i + "32") = False
Range(i + "132") = False
Range(i + "232") = False
End If

Sheets("Plant 9").Select
Range("B38").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(38, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(46, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r46c3"
Range("C38").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r46c4"
Sheets("calc").Select
Range(i + "33") = False
Range(i + "133") = False
Range(i + "233") = False
End If

Sheets("Plant 9").Select
Range("B39").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(39, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(47, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r47c3"
Range("C39").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r47c4"
Sheets("calc").Select
Range(i + "34") = False
Range(i + "134") = False
Range(i + "234") = False
End If

Sheets("Plant 9").Select
Range("B40").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(40, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(48, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r48c3"
Range("C40").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r48c4"
Sheets("calc").Select
Range(i + "35") = False
Range(i + "135") = False
Range(i + "235") = False
End If

Sheets("Plant 9").Select
Range("B41").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(41, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(49, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r49c3"
Range("C41").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r49c4"
Sheets("calc").Select
Range(i + "36") = False
Range(i + "136") = False
Range(i + "236") = False
End If

Sheets("Plant 9").Select
Range("B42").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(42, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(50, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r50c3"
Range("C42").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r50c4"
Sheets("calc").Select
Range(i + "37") = False
Range(i + "137") = False
Range(i + "237") = False
End If

Sheets("Plant 9").Select
Range("B43").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(43, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(51, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r51c3"
Range("C43").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r51c4"
Sheets("calc").Select
Range(i + "38") = False
Range(i + "138") = False
Range(i + "238") = False
End If

Sheets("Plant 9").Select
Range("B44").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(44, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(52, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r52c3"
Range("C44").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r52c4"
Sheets("calc").Select
Range(i + "39") = False
Range(i + "139") = False
Range(i + "239") = False
End If

Sheets("Plant 9").Select
Range("B45").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(45, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(53, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r53c3"
Range("C45").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r53c4"
Sheets("calc").Select
Range(i + "40") = False
Range(i + "140") = False
Range(i + "240") = False
End If

Sheets("Plant 9").Select
Range("B46").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(46, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(54, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r54c3"
Range("C46").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r54c4"
Sheets("calc").Select
Range(i + "41") = False
Range(i + "141") = False
Range(i + "241") = False
End If

Sheets("Plant 9").Select
Range("B47").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(47, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(55, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r55c3"
Range("C47").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r55c4"
Sheets("calc").Select
Range(i + "42") = False
Range(i + "142") = False
Range(i + "242") = False
End If

Sheets("Plant 9").Select
Range("B48").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(48, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(56, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r56c3"
Range("C48").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r56c4"
Sheets("calc").Select
Range(i + "43") = False
Range(i + "143") = False
Range(i + "243") = False
End If

Sheets("Plant 9").Select
Range("B49").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(49, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(57, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r57c3"
Range("C49").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r57c4"
Sheets("calc").Select
Range(i + "44") = False
Range(i + "144") = False
Range(i + "244") = False
End If

Sheets("Plant 9").Select
Range("B50").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(50, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(58, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r58c3"
Range("C50").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r58c4"
Sheets("calc").Select
Range(i + "45") = False
Range(i + "145") = False
Range(i + "245") = False
End If

Sheets("Plant 9").Select
Range("B51").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(51, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(59, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r59c3"
Range("C51").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r59c4"
Sheets("calc").Select
Range(i + "46") = False
Range(i + "146") = False
Range(i + "246") = False
End If

Sheets("Plant 9").Select
Range("B52").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(52, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(60, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r60c3"
Range("C52").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r60c4"
Sheets("calc").Select
Range(i + "47") = False
Range(i + "147") = False
Range(i + "247") = False
End If

Sheets("Plant 9").Select
Range("B53").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(53, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(61, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r61c3"
Range("C53").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r61c4"
Sheets("calc").Select
Range(i + "48") = False
Range(i + "148") = False
Range(i + "248") = False
End If

Sheets("Plant 9").Select
Range("B54").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(54, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(62, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r62c3"
Range("C54").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r62c4"
Sheets("calc").Select
Range(i + "49") = False
Range(i + "149") = False
Range(i + "249") = False
End If

Sheets("Plant 9").Select
Range("B55").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(55, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(63, 3).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r63c3"
Range("C55").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r63c4"
Sheets("calc").Select
Range(i + "50") = False
Range(i + "150") = False
Range(i + "250") = False
End If

Sheets("Plant 9").Select
Range("B56").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(56, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(14, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r14c7"
Range("C56").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r14c8"
Sheets("calc").Select
Range(i + "51") = False
Range(i + "151") = False
Range(i + "251") = False
End If

Sheets("Plant 9").Select
Range("B57").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(57, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(15, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r15c7"
Range("C57").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r15c8"
Sheets("calc").Select
Range(i + "52") = False
Range(i + "152") = False
Range(i + "252") = False
End If

Sheets("Plant 9").Select
Range("B58").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(58, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(16, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r16c7"
Range("C58").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r16c8"
Sheets("calc").Select
Range(i + "53") = False
Range(i + "153") = False
Range(i + "253") = False
End If

Sheets("Plant 9").Select
Range("B59").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(59, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(17, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r17c7"
Range("C59").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r17c8"
Sheets("calc").Select
Range(i + "54") = False
Range(i + "154") = False
Range(i + "254") = False
End If

Sheets("Plant 9").Select
Range("B60").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(60, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(18, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r18c7"
Range("C60").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r18c8"
Sheets("calc").Select
Range(i + "55") = False
Range(i + "155") = False
Range(i + "255") = False
End If

Sheets("Plant 9").Select
Range("B61").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(61, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(19, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r19c7"
Range("C61").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r19c7"
Sheets("calc").Select
Range(i + "56") = False
Range(i + "156") = False
Range(i + "256") = False
End If

Sheets("Plant 9").Select
Range("B62").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(62, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(20, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r20c7"
Range("C62").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r20c8"
Sheets("calc").Select
Range(i + "57") = False
Range(i + "157") = False
Range(i + "257") = False
End If

Sheets("Plant 9").Select
Range("B63").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(63, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(21, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r21c7"
Range("C63").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r21c8"
Sheets("calc").Select
Range(i + "58") = False
Range(i + "158") = False
Range(i + "258") = False
End If

Sheets("Plant 9").Select
Range("B64").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(64, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(22, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r22c7"
Range("C64").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r22c8"
Sheets("calc").Select
Range(i + "59") = False
Range(i + "159") = False
Range(i + "259") = False
End If

Sheets("Plant 9").Select
Range("B65").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(65, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(23, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r23c7"
Range("C65").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r23c8"
Sheets("calc").Select
Range(i + "60") = False
Range(i + "160") = False
Range(i + "260") = False
End If

Sheets("Plant 9").Select
Range("B66").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(66, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(24, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r24c7"
Range("C66").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r24c8"
Sheets("calc").Select
Range(i + "61") = False
Range(i + "161") = False
Range(i + "261") = False
End If

Sheets("Plant 9").Select
Range("B67").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(67, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(25, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r25c7"
Range("C67").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r25c8"
Sheets("calc").Select
Range(i + "62") = False
Range(i + "162") = False
Range(i + "262") = False
End If

Sheets("Plant 9").Select
Range("B68").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(68, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(26, 8).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r26c7"
Range("C68").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r26c8"
Sheets("calc").Select
Range(i + "63") = False
Range(i + "163") = False
Range(i + "263") = False
End If

Sheets("Plant 9").Select
Range("B69").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(69, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(27, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r27c7"
Range("C69").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r27c8"
Sheets("calc").Select
Range(i + "14") = False
Range(i + "114") = False
Range(i + "214") = False
End If

Sheets("Plant 9").Select
Range("B70").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(70, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(28, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r28c7"
Range("C70").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r28c8"
Sheets("calc").Select
Range(i + "65") = False
Range(i + "165") = False
Range(i + "265") = False
End If

Sheets("Plant 9").Select
Range("B71").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(71, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(29, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r29c7"
Range("C71").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r29c8"
Sheets("calc").Select
Range(i + "66") = False
Range(i + "166") = False
Range(i + "266") = False
End If

Sheets("Plant 9").Select
Range("B72").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(72, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(30, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r30c7"
Range("C72").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r30c8"
Sheets("calc").Select
Range(i + "67") = False
Range(i + "167") = False
Range(i + "267") = False
End If

Sheets("Plant 9").Select
Range("B73").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(73, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(31, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r31c7"
Range("C73").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r31c8"
Sheets("calc").Select
Range(i + "68") = False
Range(i + "168") = False
Range(i + "268") = False
End If

Sheets("Plant 9").Select
Range("B74").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(74, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(32, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r32c7"
Range("C74").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r32c8"
Sheets("calc").Select
Range(i + "69") = False
Range(i + "169") = False
Range(i + "269") = False
End If

Sheets("Plant 9").Select
Range("B75").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(75, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(33, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r33c7"
Range("C75").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r33c8"
Sheets("calc").Select
Range(i + "70") = False
Range(i + "170") = False
Range(i + "270") = False
End If

Sheets("Plant 9").Select
Range("B76").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(76, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(34, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r34c7"
Range("C76").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r34c8"
Sheets("calc").Select
Range(i + "71") = False
Range(i + "171") = False
Range(i + "271") = False
End If

Sheets("Plant 9").Select
Range("B77").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(77, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(35, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r35c7"
Range("C77").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r35c8"
Sheets("calc").Select
Range(i + "72") = False
Range(i + "172") = False
Range(i + "272") = False
End If

Sheets("Plant 9").Select
Range("B78").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(78, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(36, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r36c7"
Range("C78").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r36c8"
Sheets("calc").Select
Range(i + "73") = False
Range(i + "173") = False
Range(i + "273") = False
End If

Sheets("Plant 9").Select
Range("B79").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(79, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(37, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r37c7"
Range("C79").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r37c8"
Sheets("calc").Select
Range(i + "74") = False
Range(i + "174") = False
Range(i + "274") = False
End If

Sheets("Plant 9").Select
Range("B80").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(80, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(38, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r38c7"
Range("C80").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r38c8"
Sheets("calc").Select
Range(i + "75") = False
Range(i + "175") = False
Range(i + "275") = False
End If

Sheets("Plant 9").Select
Range("B81").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(81, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(39, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r39c7"
Range("C81").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r39c8"
Sheets("calc").Select
Range(i + "76") = False
Range(i + "176") = False
Range(i + "276") = False
End If

Sheets("Plant 9").Select
Range("B82").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(82, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(40, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r40c7"
Range("C82").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r40c8"
Sheets("calc").Select
Range(i + "77") = False
Range(i + "177") = False
Range(i + "277") = False
End If

Sheets("Plant 9").Select
Range("B83").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(83, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(41, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r41c7"
Range("C33").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r41c8"
Sheets("calc").Select
Range(i + "78") = False
Range(i + "178") = False
Range(i + "278") = False
End If

Sheets("Plant 9").Select
Range("B84").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(84, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(42, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r42c7"
Range("C84").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r42c8"
Sheets("calc").Select
Range(i + "79") = False
Range(i + "179") = False
Range(i + "279") = False
End If

Sheets("Plant 9").Select
Range("B85").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(85, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(43, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r43c7"
Range("C85").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r43c8"
Sheets("calc").Select
Range(i + "80") = False
Range(i + "180") = False
Range(i + "280") = False
End If

Sheets("Plant 9").Select
Range("B86").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(86, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(44, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r44c7"
Range("C86").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r44c8"
Sheets("calc").Select
Range(i + "81") = False
Range(i + "181") = False
Range(i + "281") = False
End If

Sheets("Plant 9").Select
Range("B87").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(87, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(45, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r45c7"
Range("C87").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r45c8"
Sheets("calc").Select
Range(i + "82") = False
Range(i + "182") = False
Range(i + "282") = False
End If

Sheets("Plant 9").Select
Range("B88").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(88, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(46, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r46c7"
Range("C88").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r46c8"
Sheets("calc").Select
Range(i + "83") = False
Range(i + "183") = False
Range(i + "283") = False
End If

Sheets("Plant 9").Select
Range("B89").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(89, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(47, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r47c7"
Range("C89").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r47c8"
Sheets("calc").Select
Range(i + "84") = False
Range(i + "184") = False
Range(i + "284") = False
End If

Sheets("Plant 9").Select
Range("B90").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(90, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(48, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r48c7"
Range("C90").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r48c8"
Sheets("calc").Select
Range(i + "85") = False
Range(i + "185") = False
Range(i + "285") = False
End If

Sheets("Plant 9").Select
Range("B91").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(91, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(49, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r49c7"
Range("C91").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r49c8"
Sheets("calc").Select
Range(i + "86") = False
Range(i + "186") = False
Range(i + "286") = False
End If

Sheets("Plant 9").Select
Range("B92").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(92, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(50, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r50c7"
Range("C92").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r50c8"
Sheets("calc").Select
Range(i + "87") = False
Range(i + "187") = False
Range(i + "287") = False
End If

Sheets("Plant 9").Select
Range("B93").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(93, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(51, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r51c7"
Range("C93").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r51c8"
Sheets("calc").Select
Range(i + "88") = False
Range(i + "188") = False
Range(i + "288") = False
End If

Sheets("Plant 9").Select
Range("B94").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(94, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(52, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r52c7"
Range("C94").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r52c8"
Sheets("calc").Select
Range(i + "89") = False
Range(i + "189") = False
Range(i + "289") = False
End If

Sheets("Plant 9").Select
Range("B95").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(95, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(53, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r53c7"
Range("C95").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r53c8"
Sheets("calc").Select
Range(i + "90") = False
Range(i + "190") = False
Range(i + "290") = False
End If

Sheets("Plant 9").Select
Range("B96").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(96, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(54, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r54c7"
Range("C96").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r54c8"
Sheets("calc").Select
Range(i + "91") = False
Range(i + "191") = False
Range(i + "291") = False
End If

Sheets("Plant 9").Select
Range("B97").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(97, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(55, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r55c7"
Range("C97").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r55c8"
Sheets("calc").Select
Range(i + "92") = False
Range(i + "192") = False
Range(i + "292") = False
End If

Sheets("Plant 9").Select
Range("B98").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(98, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(56, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r56c7"
Range("C98").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r56c8"
Sheets("calc").Select
Range(i + "93") = False
Range(i + "193") = False
Range(i + "293") = False
End If

Sheets("Plant 9").Select
Range("B99").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(99, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(57, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r57c7"
Range("C99").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r57c8"
Sheets("calc").Select
Range(i + "94") = False
Range(i + "194") = False
Range(i + "294") = False
End If

Sheets("Plant 9").Select
Range("B100").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(100, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(58, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r58c7"
Range("C100").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r58c8"
Sheets("calc").Select
Range(i + "95") = False
Range(i + "195") = False
Range(i + "295") = False
End If

Sheets("Plant 9").Select
Range("B101").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(101, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(59, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r59c7"
Range("C101").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r59c8"
Sheets("calc").Select
Range(i + "96") = False
Range(i + "196") = False
Range(i + "296") = False
End If

Sheets("Plant 9").Select
Range("B102").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(102, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(60, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r60c7"
Range("C102").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r60c8"
Sheets("calc").Select
Range(i + "97") = False
Range(i + "197") = False
Range(i + "297") = False
End If

Sheets("Plant 9").Select
Range("B103").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(103, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(61, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r61c7"
Range("C103").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r61c8"
Sheets("calc").Select
Range(i + "98") = False
Range(i + "198") = False
Range(i + "298") = False
End If

Sheets("Plant 9").Select
Range("B104").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(104, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(62, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r62c7"
Range("C104").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r62c8"
Sheets("calc").Select
Range(i + "99") = False
Range(i + "199") = False
Range(i + "299") = False
End If

Sheets("Plant 9").Select
Range("B105").Select
If Workbooks("FMLAMaster.xls").Sheets("Plant 9").Cells(105, 2).Value <> Workbooks("9FMLA.xls").Sheets("employee guide").Cells(63, 7).Value Then
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r63c7"
Range("C105").Select
ActiveCell.Formula = "='[9FMLA.xls]employee guide'!r63c8"
Sheets("calc").Select
Range(i + "100") = False
Range(i + "200") = False
Range(i + "300") = False
End If


Sheets("Plant 9").Select
Range("B6:C105").Select
Selection.Copy
Selection.PasteSpecial Paste:=xlValues, operation:=xlNone, skipblanks:=False, Transpose:=False
Sheets("calc").Select
Range("T2").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r8c26"
Range("T3").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r22c29"
Range("T4").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r24c29"
Range("T5").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r26c29"
Range("T6").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r28c29"
Range("T7").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r32c29"
Range("T8").Select
ActiveCell.Formula = "='[9fmla.xls]Report'!r34c29"
Range("T2:T8").Select
Selection.Copy
Selection.PasteSpecial Paste:=xlValues, operation:=xlNone, skipblanks:=False, Transpose:=False
Windows("9FMLA.xls").Activate
ActiveWorkbook.RunAutoMacros Which:=xlAutoClose
ActiveWindow.Close (savechanges = True)
Application.ScreenUpdating = True
Sheets("calc").Select
Range("M1").Select
ActiveCell.Copy
Sheets("Plant 9").Select
Range("B6").Select
Application.EnableEvents = True
Application.DisplayFullScreen = True
End Sub

Thanks Nathan
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
Hi Nathan,

The problem with your code, as you have probably noticed, is that there is an awful lot of repetition. What you need to do is to adopt a 'loop' approach in your code such that only the variable parts are changed.

Compare the two routines below:
Code:
Sub Loopy()
Worksheets("Sheet1").Range("A1").Value = 1
Worksheets("Sheet1").Range("A2").Value = 2
Worksheets("Sheet1").Range("A3").Value = 3
'
'etc
'etc
'
Worksheets("Sheet1").Range("A1000").Value = 1000
End Sub

Sub Loopy2()
Dim l As Long, ws As Worksheet
Set ws = Worksheets("Sheet1")
For l = 1 To 1000
    ws.Range("A" & l).Value = l
Next
End Sub
Try to adopt this approach on your code. I'm afraid I don't have time at the moment to go through and adjust your code - maybe later.

The ironic thing is, once you start using loops you'll start to look for ways to avoid them! We'll leave that discussion to another day :wink:

HTH
 
Upvote 0

Forum statistics

Threads
1,223,910
Messages
6,175,318
Members
452,634
Latest member
cpostell

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