DimensionAssociateWith Method
The DimensionAssociateWith method associates a source object with a new DateDimension object and adds an Association object to the Associations collection.
Syntax
DateWizard .DimensionAssociateWith Reference, Role [, Context]
Applies To
Discussion
Use this method to associate a DateDimension object with an object in a data source. The Reference parameter performs the same function as the Reference property of an Association object. The Role parameter performs the same function as the AssociationRole property. The Context parameter performs the same function as the Context property.
When you use the DimensionAssociateWith method, it adds an Association object to the Associations collection of the DateDimension object.
A COM exception is thrown in error situations. The message that is passed with the exception varies depending on the error situation.
Parameter |
Description |
---|---|
Reference |
Required. Specifies the source of the association. Type: Object |
Role |
Required. Specifies how the reference is used. This parameter uses a constant of the value list xtrAssociationRole. Type: Constant - xtrAssociationRole |
Context |
Required for OrderBy Associations. Specifies the drill-down path in which a level is sorted. Applies to Level and DateLevel objects only. Type: Object |
Return Type
None
Examples
objDateWizard = objModel.DateWizardobjDateWizard.DimensionAssociateWith
(objColumn, xtrAssociationRole.trAssociationSource)