功能:將一個Sheets("總表")中的值賦給Sheets("評估").,在“評估”表中得出結果後再返回到Sheets("總表")中。
Sub 評估()
Dim x As Integer, y As Integer
y = Sheet1.Range("l65536").End(xlUp).Row '尋找一列中最後一個非空值的行號
For x = 2 To y
Sheets("評估").Cellls(4,“C”) = Sheets("總表").Cells(x, "L")
Sheets("評估").Cells(6, "C") = Sheets("總表").Cells(x, "M")
Sheets("評估").Cells(5, "C") = Sheets("總表").Cells(x, "P")
Sheets("總表").Cells(x, "Q") = Sheets("評估").Cells(18, "C")
Next x
End Sub