Microsoft Office Tutorials and References
In Depth Information
19.1 The Range Object as a Collection
ColumnDifferences
Item
Speak<v10>
Columns
Justify
SpecialCells
ColumnWidth
Left
Style
Comment
ListHeaderRows
SubscribeTo
Consolidate
ListNames
Subtotal
Copy
LocationInTable
Summary
CopyFromRecordset
Locked
Table
CopyPicture
Merge
Text
Count
MergeArea
TextToColumns
CreateNames
MergeCells
Top
CreatePublisher
Name
Ungroup
Creator
NavigateArrow
UnMerge
CurrentArray
Next
UseStandardHeight
CurrentRegion
NoteText
UseStandardWidth
Cut
NumberFormat
Validation
DataSeries
NumberFormatLocal
Value
Delete
Offset
Value2
Dependents
Orientation
VerticalAlignment
DialogBox
OutlineLevel
Width
DirectDependents
PageBreak
Worksheet
DirectPrecedents
Parent
WrapText
Dirty<v10>
Parse
EditionOptions
PasteSpecial
Our plan in this chapter is first to explore ways of defining Range objects. Then we will discuss
many of the properties and methods of this object, as indicated in Table 19-1 . As we have
mentioned, our goal is not to cover all aspects of the Excel object model, but to cover the main
portions of the model and to provide you with a sufficient foundation so that you can pick up
whatever else you may need by using the help system.
19.1 The Range Object as a Collection
The Range object is rather unusual in that it often acts like a collection object as well as a
noncollection object. For instance, it has an Item method and a Count property. On the other hand,
the Range object has many more noncollection-type members than is typical of collection objects.
In particular, the average member count among all other collection objects is 19, whereas the
Range object has 158 members.
Indeed, the Range object should be thought of as a collection object that can hold other Range
objects. To illustrate, consider the following code:
Dim rng as Range
Set rng = Range("A1", "C5").Cells
MsgBox rng.Count ' displays 15
Set rng = Range("A1", "C5").Rows
MsgBox rng.Count ' displays 5
 
Search JabSto ::




Custom Search