Hi all
Hi have code belove will adding value (like =sum) from multiple sheet to master
But now I all value will be combine (not add), so please help me change code to do that
thanks./.
Hi have code belove will adding value (like =sum) from multiple sheet to master
But now I all value will be combine (not add), so please help me change code to do that
thanks./.
Code:
[COLOR=#141414][FONT=inherit]For Each k In .SelectedItems[/FONT][/COLOR]<code style="box-sizing: border-box; font-family: inherit; font-size: 1em;"> Set Wb = Workbooks.Open(k)
arr1 = Wb.Sheets("PL1").Range("C9:I57").Value
arr2 = Wb.Sheets("PL2").Range("C9:v81").Value
arr3 = Wb.Sheets("PL3").Range("C9:AU81").Value
Wb.Close False
For i = 1 To UBound(arr1, 1)
For j = 1 To UBound(arr1, 2)
If arr1(i, j) <> Empty And IsNumeric(arr1(i, j)) = True Then
dArr1(i, j) = dArr1(i, j) + arr1(i, j)
End If
Next j
Next i
For i = 1 To UBound(arr2, 1)
For j = 1 To UBound(arr2, 2)
If arr2(i, j) <> Empty And IsNumeric(arr2(i, j)) = True Then
dArr2(i, j) = dArr3(i, j) + arr2(i, j)
End If
Next j
Next i
For i = 1 To UBound(arr3, 1)
For j = 1 To UBound(arr3, 2)
If arr3(i, j) <> Empty And IsNumeric(arr3(i, j)) = True Then
dArr3(i, j) = dArr3(i, j) + arr3(i, j)
End If
Next j
Next i
Next
End With
Sheets("PL1").Range("C9:I57").Value = dArr1
Sheets("PL2").Range("C9:v81").Value = dArr2 </code>[COLOR=#141414][FONT=inherit] Sheets("PL3").Range("C9:AU81").Value = dArr3[/FONT][/COLOR]