Microsoft Office Tutorials and References
In Depth Information PatternColor and PatternColorIndex properties
xlPatternGray16 = 17
xlPatternGray8 = 18
End Enum
Note that this provides another way to access grayscales. PatternColor and PatternColorIndex properties
These properties set the color (or color index) of the pattern used to fill the interior of a cell. For
more on setting color and color indexes, please see the discussion of the Color and ColorIndex
properties of the Border object.
19.4.9 The PivotField, PivotItem, and PivotTable Objects
These objects relate to PivotTable objects and will be discussed in Chapter 20 .
19.4.10 The QueryTable Object
A QueryTable object represents a worksheet table that is built from data returned from an external
data source, such as Microsoft SQL Server or a Microsoft Access database. We will not discuss
QueryTable objects in this topic. (There are better ways to retrieve data from an external source.)
19.4.11 The Validation Object
A Validation object is used to enforce data validation on a cell or range of cells. The Validation
property of the Range object returns a Validation object, whose properties can be returned or set.
Note that there is no Validations collection.
Data validation involves three parts: the actual validation, an input message that can be displayed
when a cell is activated, and an error message that can be displayed if the data entered is invalid.
The methods of the Validation object are Add, Delete, and Modify. To add validation to a range,
use the Add method, whose syntax is:
ValidationObject .Add( Type , AlertStyle , Operator , Formula1 , Formula2 )
Note the similarity between the parameters of the Add method of the Validation object and the
Add method of the FormatConditions object.
The required Type parameter specifies the type of data allowed and can be one of the following
XlDVType constants:
Enum XlDVType
xlValidateInputOnly = 0
xlValidateWholeNumber = 1
xlValidateDecimal = 2
xlValidateList = 3
xlValidateDate = 4
xlValidateTime = 5
xlValidateTextLength = 6
xlValidateCustom = 7
End Enum
Search JabSto ::

Custom Search