Its me again.
 
why do you want to use already existing function abs()?
This makes your life easier.
 
/*********************************************************************************/
 return Abs(InventJournalTrans_Qty)will return the absolute ( positve ) value.
 
/********************************************************************************/

Varden Morris <[EMAIL PROTECTED]> wrote:
Bob
 
I see nothing wrong with the method away from the bracket that comes before you assign a value to the variable result.

[EMAIL PROTECTED] wrote:

Hi All,

I am trying to convert a negative number to positive for a report and am
getting errors:

1-Unknown source for data method Quantity
2-Operand Types are not compatible with the operator.

Can anyone tell me what I am doing wrong? InventJournalTrans_Qty is a field
in my report.

My method is as follows:

    display real Quantity()
{
       real result;
//
    if (InventJournalTrans_Qty < 0)
    )
    result =  InventJournalTrans_Qty * -1;
    else
    result =  InventJournalTrans_Qty * 1;
    //
    return result;
}

Thanks in advance for this and the help I have received. I sincerely
appreciate it.

Bob


Bob Brinker
Oakdene Group, Inc.
2625 Butterfield Rd. (Suite 212E)
Oak Brook, IL 60523-1261
[EMAIL PROTECTED]



Sharing the knowledge on Axapta.



Do you Yahoo!?
vote.yahoo.com - Register online to vote today!

Sharing the knowledge on Axapta.


__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com

Sharing the knowledge on Axapta.


Yahoo! Groups Sponsor
ADVERTISEMENT
click here


Yahoo! Groups Links

Reply via email to