Thread: Dynamic Range
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Dynamic Range

Hi,

Sub TEST()

cnt = ActiveSheet.Range("D1").MergeArea.Columns.Count
MsgBox "Number of columns are " & cnt

End Sub


(In your file, D1 is the first cell of columns the Machines have.)


--
Regards,
Soo Cheon Jheong
_ _
^вп^
--