Original code is to big to publish. The code here is just an example of what is used in the original. I just found out that somehwere in my code one of the variables was quoted like "$B". After removing the quotes and change the local code to
$C=$B and using $C for the quoted statement the the calculation went Ok. (Still strange..)

[ 11 July 2001: Message edited by: Loekw ]