How to do cells(x,y) for merged field

  • Thread starter Thread starter Piotr
  • Start date Start date
P

Piotr

I have huge problem I cant get data from merged cell it is 4-5,9 in
excell when i try to point
CELLS(4,9) it returns null
cells(5,9) return null as well

how can i get this data I cant change the .xls file
 
I cannot reproduce your problem. You do understand that the order of
arguments in Cells() is row, column?

I merged cells I4:I5 and filled the meged cell with "Eureka!" and ran
the following macro

Sub tryit()
For i = 4 To 5
Cells(i, 1) = Range("I" & i).Value
Cells(i, 2) = Cells(i, 9).Value
Next i
End Sub

which put "Eureka!" into A4:B4 and 0 into A5:B5

Jerry
 
Try to avoid merged cells at all costs, as they will cause you heartache in
exchange for little or (usually) no benefit.
 
Back
Top