Adds a PropertyTest object to the PropertyTests collection.
Syntax
expression.Add(Name, Condition, Value, SecondValue, Connector)
expression An expression that returns a PropertyTests object.
Name Required String. The name of the property criterion. The name corresponds to a value in the Property box in the Find dialog box, which you open from the Tools menu in the application's Open dialog box (File menu).
Condition Required Variant. The condition of the search criteria. Can be one of the following MsoCondition constants:
msoConditionAnyNumberBetween
msoConditionAnytime msoConditionAnytimeBetween msoConditionAtLeast msoConditionAtMost msoConditionBeginsWith msoConditionDoesNotEqual msoConditionEndsWith msoConditionEquals msoConditionFileTypeAllFiles msoConditionFileTypeBinders msoConditionFileTypeDatabases msoConditionFileTypeExcelWorkbooks msoConditionFileTypeOfficeFiles msoConditionFileTypePowerPointPresentations msoConditionFileTypeTemplates msoConditionFileTypeWordDocuments msoConditionIncludes msoConditionIncludesNearEachOther msoConditionIncludesPhrase |
msoConditionInTheLast
msoConditionInTheNext msoConditionIsExactly msoConditionIsNo msoConditionIsNot msoConditionIsYes msoConditionLastMonth msoConditionLastWeek msoConditionLessThan msoConditionMoreThan msoConditionNextMonth msoConditionNextWeek msoConditionOn msoConditionOnorAfter msoConditionOnorBefore msoConditionThisMonth msoConditionThisWeek msoConditionToday msoConditionTomorrow msoConditionYesterday |
Value Optional Variant. The value of the search criterion.
SecondValue Optional Variant. An upper value for the search range. You can use this argument only if Condition is msoConditionAnyTimeBetween or msoConditionAnyNumberBetween.
Connector Optional Variant. Specifies the way two search criteria are combined. Can be either of the following MsoConnector constants: msoConnectorAnd or msoConnectorOr.