Hello,
I would like to use an Internal Boolean parameter in the VBA script for the IF...function. Is there any suggestion or the below will work:
If DVSYS.MODULE/PARAMETER.F_CV = False Then msgOper = "The parameter is False" Else msgOper = "The parameter is True" End If
Hi Morreira
It may works, but .implicit conversion could give some strange behavior.
For example, this code will return False because the converted Integer value for True is -1
If 1 = True Then Debug.Print "True" Else Debug.Print "False" End If
The best practice is to explicitly convert data type.
This code will return True :
If CBool(1) = True Then
Jack
In reply to Jack_France: