General information
Category:
Coding, syntax & commands
Hi,
The ntotDetail is Numeric I din't assign it to currency and also ntotExpense
NOTE:
I did not assign currency to all my table i used Numeric 10,2
TIA
>Hi,
>
>May you be more specific on used tables' structure. How do you calculate ntotDetail and ntotExpense? Check type of ntotDetail and ntotExpense ( example ? Type("ntotDetail")) it shouldn't be "Y", which stands for currency.
>
>>Hi...
>>
>> Thanks. but I declare it as a Numeric not currency, and still the computation is wrong....
>>
>>TIA
>>
>>
>>>>>Try to use
>>>>>
>>>>>scan for
>>>>> nTemp = field1
>>>>> * nTemp is a local variable
>>>>> nAll=(nTemp/ntotDetail)*ntotExpense
>>>>>endscan
>>>>
>>>>still the same as the result
>>>
>>>Sorry for the first reply.
>>>Seemingly field1 has data type "Currency", which provides precision 4 decimals.
>>>Conversion to data type "Numeric" does the trick:
>>>
>>>scan for
>>> nAll=(MtoN(field1)/ntotDetail)*ntotExpense
>>>endscan
>>>
>>>Sincerely,
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only