Had the same problem not too long ago ,just Add in
decround(Amount,Decimal spaces function something like

inventJournalTrans.costPrice =
decround(PriceDisc::amount2Price(inventJournalTrans.costAmount,0,0,
inventJournalTrans.qty,0,1,'',0)),2);



Hope it helps

Jason





________________________________

From: Baran Sasmaz [mailto:[EMAIL PROTECTED]
Sent: 20 July 2004 19:24
To: [EMAIL PROTECTED]
Subject: [development-axapta] Create Profit/Loss journal from code



Hi,

I create profit/loss journal and their lines from code. When i insert a
journal line, i have  the quantity and the cost amount of the record and
I calculate the cost price by using the formula given below :

inventJournalTrans.costPrice =
PriceDisc::amount2Price(inventJournalTrans.costAmount,
                                                              0,
                                                              0,

inventJournalTrans.qty,
                                                              0,
                                                              1,
                                                              '',
                                                              0);

I know that the system also calculates the cost price in this way.

But when i try to validate or post the journal, system gives me the
error below :

"Incorrect rounding of amount"

If i modify the cost price or the cost amount ON THE FORM and finally i
see the same price and amount as before, it validates. I couldn't
understand!!!

May someone help me???

Thankx in advance.

           
---------------------------------
Do you Yahoo!?
Vote for the stars of Yahoo!'s next ad campaign!

[Non-text portions of this message have been removed]






Yahoo! Groups Sponsor

ADVERTISEMENT
click here
<http://us.ard.yahoo.com/SIG=129a31eae/M=295196.4901138.6071305.3001176/
D=groups/S=1705006764:HM/EXP=1090441159/A=2128215/R=0/SIG=10se96mf6/*htt
p:/companion.yahoo.com>


<http://us.adserver.yahoo.com/l?M=295196.4901138.6071305.3001176/D=group
s/S=:HM/A=2128215/rand=824843399>



________________________________

Yahoo! Groups Links

*      To visit your group on the web, go to:
      http://groups.yahoo.com/group/development-axapta/
       
*      To unsubscribe from this group, send an email to:
      [EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]
be>
       
*      Your use of Yahoo! Groups is subject to the Yahoo! Terms of
Service <http://docs.yahoo.com/info/terms/> .



[Non-text portions of this message have been removed]



Yahoo! Groups Sponsor
ADVERTISEMENT
click here


Yahoo! Groups Links

Reply via email to