Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Function module

madan_ullasa
Contributor
0 Likes
670

frnds,

any1 aware of a function module to convert a number in exponential form to normal form...

eg... a no. like 1.2000000000E+1 to 12....

Points assured to 1 and all....

Madan.....

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
637

The write statement will do it for you by default.

8 REPLIES 8
Read only

Former Member
0 Likes
637

Hi,

Switch on the FIXED POINT ARITHMETIC check box in the attributes of the program. That will be done for you.

Regards,f

Ravi

Read only

Former Member
0 Likes
638

The write statement will do it for you by default.

Read only

former_member181966
Active Contributor
0 Likes
637

I dont find any FM , but you can use <u><b>EXP</b></u> (Mathematical function: Exponential function ) !!

Hope this’ll give you idea!!

<b>P.S award the points.</b>

Good luck

Thanks

Saquib Khan

"Some are wise and some are otherwise"

Read only

Former Member
0 Likes
637

Madan,

You can do it using write statement...eg..

The output of the WRITE statement is "1,414". The standard output for an output length of 6 would be "1E+00".

DATA float TYPE f.

float = sqrt( 2 ).

WRITE (6) float EXPONENT 0.

Cheers,

Nilesh

Read only

vinod_gunaware2
Active Contributor
0 Likes
637

use <b>write to</b> or directly assing variable I or num

regards

vinod

Read only

suresh_datti
Active Contributor
0 Likes
637

try this..


data: w_num type f  value '1.2000000000E+1',
      w_num1 type i.

w_num1 =  abs( w_num ).

write:/ w_num,w_num1.

regards,

Suresh datti

Read only

Former Member
0 Likes
637

Hi,

Check this below code.

DATA v_field TYPE f.

WRITE your field TO v_field.

cheers,

Bujji

Read only

Former Member
0 Likes
637

Check this code:

DATA float TYPE f value '1.2000000000E+1'.

WRITE (6) float EXPONENT 0.

Its working.

REgards,

Ravi