Consultor Eletrônico



Kbase 17440: Actuate - Problem with divide by zero
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   10/05/1998
Actuate - Problem with divide by zero


Actuate has a problem with IIF() and divide by zero.
One workaround for this problem is to write an external basic
function.

Once the file is included in your design file, by just simply doing
include Basic file, then all the controls can then access this
function by just simply calling this function from the Value
Expression.

For example if you do X/Y in your ValueExpression the all you have
to do is call DivideByZero(X,Y) in your Value Expression.

The advantage of having this function in an external basic file is
all the design files can acccess it rather than having to write the
function all over again.


******************************************************************
Example of Master.bas

Function DivideByZero(Quotient as Double, Divisor as Double)
As Variant
If Divisor = 0 Then
DivideByZero = 0
Else
DivideByZero = Quotient/Divisor
End If
End Function

********************************************************************

Progress Software Technical Support Note # 17440