VarIdiv Function
Converts two variants of any type to integers then returns the result from dividing them.
HRESULT VarIdiv( LPVARIANT pvarLeft, LPVARIANT pvarRight, LPVARIANT pvarResult );
The function returns one of the following:
If | Then |
|---|---|
Both expressions are of the string, date, character, boolean type | Division and interger is returned. |
One expression is a string type and the other a character | Division. |
One expression is numeric and the other is a string | Division. |
Both expressions are numeric | Division. |
Either expression is NULL | NULL is returned. |
Both expressions are empty | DISP_E_DIVBYZERO |