2006 Sep 10 8:58 PM
I am working with subroutine pool program for script (becasue I must use standard driver program and script):
In my subroutine pool program, I need to change currency format for some variables more frequently according to user setttings ( need to do calculations so need to change formats before and after calculations ).
<b>Is it possible to write one perform and use this perform subroutine again and again:
I mean is it ok, if we write PERFROM statement in subroutine pool program and use again and again ?</b><b>If it is not possible... How to change currency format for calculations and again back to user format ?</b>Please help me...Thanks in advance...
I am working with subroutine pool program for script (becasue I must use standard driver program and script):
In my subroutine pool program, I need to change currency format for some variables more frequently according to user setttings ( need to do calculations so need to change formats before and after calculations ).
<b>Is it possible to write one perform and use this perform subroutine again and again:
I mean is it ok, if we write PERFROM statement in subroutine pool program and use again and again ?</b><b>If it is not possible... How to change currency format for calculations and again back to user format ?</b>Please help me...Thanks in advance...
2006 Sep 10 9:11 PM
Hi,
you can not write a Perform in the Subroutine pool program but you can create a include program then it may possible in that one, try it
Regards
Sudheer
2006 Sep 10 9:13 PM
Hi
You can create a subroutine but what does mean <b>'again and again'</b>?
If it means to isert in a cycle (like DO/ENDDO) you can't, but you can call it everytime you need.
Max
2006 Sep 10 9:51 PM
again means each value/variable coming into program has to change
say for example from 3,456,478.99 to 345647899 add some amount like 2000...
and again convert back 3,456,498.99 ...
I have to change for each varible like above and add and again change back to original format.
Please ask me again if you don't understand . Will tell you more clearly..
2006 Sep 10 10:17 PM
Hi
A sapscript can see all variable defined in driver program as global data, so you can pass them in the routine:
/: PERFORM <FORM> IN PROGRAM <PROAGRAM>
/: USING <VARIABLE 1>
/: USING <VARIABLE 2>
/: USING ............
/: CHANGING <VARIABLE 1>
/: CHANGING ............
MAx
2006 Sep 10 10:34 PM
This I am doing in subroutine pool program not in script editor . I need to do calculation... can I do in script editor and again change it into required format ?
2006 Sep 10 10:39 PM
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |