Logo 
Search:

MS Office Answers

Ask Question   UnAnswered
Home » Forum » MS Office       RSS Feeds
  Question Asked By: Carolina Lopez   on Nov 08 In MS Office Category.

  
Question Answered By: Alfie Evans   on Nov 08

to follow up on what I posted previously... this seems to work. I'm
still interested in what others are doing for this type  of problem
though....

Dim FlagArray As Range
Dim ValueArray As Range
Dim i As Long, j As Long

Set FlagArray = Range("FlagArray")
Set ValueArray = Range("ValueArray")

For i = 1 To FlagArray.Rows.Count
For j = 1 To FlagArray.Columns.Count

If FlagArray.Cells(i, j).Value = "X" Then
ValueArray.Cells(i, j).Value = 2

End If
Next j
Next i
End Sub

Share: