• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

To understand the Range, cell funtion

With Range(Cells(reason_count + 18, 1), Cells(2 * reason_count + 17, 7))
.ClearContents
.Interior.Color = 16777215
End With
With Range(Cells(2 * reason_count + 38, 1), Cells(3 * reason_count + 37, 7))
.ClearContents
.Interior.Color = 16777215
End With
----------------------------------------------------------------------------
 
Range() can be specified as:
Range("A1")
or
Range("A1:H5")
or
Range(Cells(2 * reason_count + 38, 1), Cells(3 * reason_count + 37, 7))
etc


in the last example Range will have a value from the cell at A (2 * reason_count + 38) to
G 3 * reason_count + 37

eg: if reason_count is 10
The Range will be A58:G67
 
Back
Top