Platform SDK: MAPI |
The IMAPIProgress::SetLimits method sets the lower limit for the number of items operated on, the maximum number of items operated on, and the flags that control how progress information is calculated for the operation in question.
HRESULT SetLimits( LPULONG lpulMin, LPULONG lpulMax, LPULONG lpulFlags );
Service providers call IMAPIProgress::SetLimits to set or clear the MAPI_TOP_LEVEL flag and to set local and global minimum and maximum values. The value of the flags setting affects whether the progress object understands the minimum and maximum values to be local or global. When the MAPI_TOP_LEVEL flag is set, these values are considered global and are used to calculate progress for the entire operation. Progress objects initialize the global minimum value to 1 and the global maximum value to 1000.
When MAPI_TOP_LEVEL is not set, the minimum and maximum values are considered local and are used internally by providers to display progress for lower level subobjects. Progress objects save the local minimum and maximum values only so that they can be returned to providers when GetMin and GetMax are called.
For more information about implementing SetLimits and the other IMAPIProgress methods, see Implementing a Progress Indicator.
For more information about how and when to make calls to a progress object, see Displaying Progress Step by Step.