‎2008 Feb 18 6:01 AM
hi,
when i write below statment i get error
WRITE : ( s_amt7 * 20 ) / 100.
can we do arithmetic function like above in write stament ?
‎2008 Feb 18 6:05 AM
Santhosh,
Declare one variable and then perform the arthemetic calculation using that variable and then write that variable.
Data: Var1
Var1 = ( s_amt7 * 20 ) / 100.
WRITE : var1.
Regards..
‎2008 Feb 18 6:15 AM
Hi
we cannot use arithmetic statements in write statement
declare a variable and call that in write statement.
a = ( s_amt7 * 20 ) / 100.
write 😕 a.
‎2008 Feb 18 6:18 AM
Hi,
Do your calculations first, keep the result in a variable, then try to display the value or variable.
lv_cal = ( s_amt7 * 20 ) / 100.
WRITE : lv_cal.
Rgds,
Bujji
‎2008 Feb 18 6:19 AM
Hi
try this way,u can get the output.
data: s_amt7 type i value 1000.
data: var1 type i, var2 type i.
var1 = s_amt7 * 20.
var2 = var1 / 100.
write var2.
Thanks,
chandu.