'Delivered
TempArray(Currenti, colSummaryDelivered) = _
"=SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Company""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingRevenue), Cells(65536, colBookingRevenue)).Address & ") + SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/RoomHire""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingRevenue), Cells(65536, colBookingRevenue)).Address & ") + SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Onsite""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingRevenue), Cells(65536, colBookingRevenue)).Address & ") + SUMIF(Public!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Public""" & _
", Public!" & Range(Cells(intSheetStartRow, colBookingRevenue), Cells(65536, colBookingRevenue)).Address & ") + SUMIF(3Party!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/3Party""" & _
", 3Party!" & Range(Cells(intSheetStartRow, colBookingRevenue), Cells(65536, colBookingRevenue)).Address & ")"
'DeliveredCost
TempArray(Currenti, colSummaryDeliveredCost) = _
"=SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Company""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingCost), Cells(65536, colBookingCost)).Address & ") + SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/RoomHire""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingCost), Cells(65536, colBookingCost)).Address & ") + SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Onsite""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingCost), Cells(65536, colBookingCost)).Address & ") + SUMIF(Public!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Public""" & _
", Public!" & Range(Cells(intSheetStartRow, colBookingCost), Cells(65536, colBookingCost)).Address & ") + SUMIF(3Party!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/3Party""" & _
", 3Party!" & Range(Cells(intSheetStartRow, colBookingCost), Cells(65536, colBookingCost)).Address & ")"
'DeliveredMargin
TempArray(Currenti, colSummaryDeliveredMargin) = _
"=SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Company""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingMargin), Cells(65536, colBookingMargin)).Address & ") + SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/RoomHire""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingMargin), Cells(65536, colBookingMargin)).Address & ") + SUMIF(Private!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Onsite""" & _
", Private!" & Range(Cells(intSheetStartRow, colBookingMargin), Cells(65536, colBookingMargin)).Address & ") + SUMIF(Public!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/Public""" & _
", Public!" & Range(Cells(intSheetStartRow, colBookingMargin), Cells(65536, colBookingMargin)).Address & ") + SUMIF(3Party!" & Range(Cells(intSheetStartRow, colBookingKey1), Cells(65536, colBookingKey1)).Address & _
", " & Range(Cells(intRow, colSummaryKey1), Cells(intRow, colSummaryKey1)).Address & " & ""/3Party""" & _
", 3Party!" & Range(Cells(intSheetStartRow, colBookingMargin), Cells(65536, colBookingMargin)).Address & ")"
'Delivered Margin %
TempArray(Currenti, colSummaryDeliveredMarginPerc) = _
"=IF(R" & intRow & "C" & colSummaryDelivered & "<>0,R" & intRow & "C" & colSummaryDeliveredMargin & "/" & "R" & intRow & "C" & colSummaryDelivered & ",0)"
Bookmarks