.Value "issue"
Hi Ray,
Am Mon, 29 Jun 2015 10:53:17 -0700 (PDT) schrieb Ray:
The formula in AG5 is a vlookup, which uses looks up the value in column A and the # of columns to count over referenced in the same column (so, for original coding, lookup-column value is in AG4).
try it this way:
Sub Run37Hours()
Dim rngC As Range, myRng As Range
Dim mySum As Double
With Sheets("Sheet2")
.Unprotect
'feed in the values
Set myRng = .Range("AG19, AG21:AG27, AG29:AG35, AG39:AG44, AG47,
AG49, AG52, AG55:AG60, AG63:AG66, AG69, AG73:AG78")
With myRng
.Formula = Range("AG5").Formula
For Each rngC In myRng
rngC.Value = rngC.Value
Next
End With
.Protect
End With
End Sub
Regards
Claus B.
--
Vista Ultimate / Windows7
Office 2007 Ultimate / 2010 Professional
|