on 04-12-2009 12:53 PM
Hi All,
I have to create a SAP Script for Cheque Printing.It Consists of 3 segments:
1)Header Data
2)Table Data
3)Cheque Data
I am facing the problem in table data.Table data have 2 sections & each section have 3 coloumns of date,your ref & Net amount.The program has to take value from table fields:REGUP-BUDAT,REGUP-XBLNR,REGUP-DMBTR.Print prog is RFFOUS_C.
Prog shall be able to print 25 lines in each section so that it could print max of 50 Rows.
Table data Format:
Date Your Ref Net Amount | Date Your Ref Net Amount
01/01/2002 100-1 1033 | 01/01/2005 200-1 2000
02/01/2002 100-2 1010 | 02/01/2005 200-2 2005
03/01/2002 100-3 1020 | 03/01/2005 200-3 8790
04/01/2002 100-4 1030 | 04/01/2009 200-4 2015
05/01/2002 100-5 1040 | 05/01/2009 200-5 2020
06/01/2002 100-6 3789 | 06/01/2009 200-6 2025
07/01/2002 100-7 1060 | 07/01/2009 200-7 2030
08/01/2002 100-8 1070 | 08/01/2006 200-8 7648
09/01/2002 100-9 1080 | 09/01/2006 200-9 2040
10/01/2002 100-10 1090 | 10/01/2009 200-10 2045
11/01/2002 100-11 1100 | 11/01/2009 200-11 2050
12/01/2002 100-12 9879 | 12/01/2009 200-12 2055
13/01/2002 100-13 1120 | 13/01/2009 200-13 2060
14/01/2002 100-14 1130 | 14/01/2009 200-14 2065
15/01/2002 100-15 1140 | 15/01/2009 200-15 2070
16/01/2002 100-16 1150 | 16/01/2009 200-16 2075
23/01/2009 100-23 1220 | 23/01/2009 200-23 2110
24/01/2009 100-24 1230 | 24/01/2009 200-24 2115
25/01/2009 100-25 1240 | 25/01/2009 200-25 2120
Cheque Total (Print Total)
Lets suppose there r 45 records then it should print 25 lines in 1st section and remaining 20 lines in 2nd section.
I am unable to print the same in 2 sections.Pls help me in resolving this.
Thanxs.
Hi,
Could you try by creating another instance of main window. As we know that we could create max. of 99 instances of MAIN window in a page, create another instance of MAIN window and print the data in instance 01 from 26th record onwards.
Regards,
Prasanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
1. First U describe the lines in Ur Table data in driver program.
2. check if the Lines are more 25. If More than 25 lines, then write another condition like below.
Eg: Number of lines in Table Data is 45.
data : table_lines TYPE i value 45,
lv_index type i.
LOOP at table_data.
lv_index = lv_index + 1.
IF v_index GT 25.
CALL FUNCTION 'CONTROL_FORM'
EXPORTING
command = 'NEW-PAGE'.
table_lines = table_lines - 25.
CLEAR : lv_index.
ENDIF.
ENDLOOP.
by doing above, for every 25 lines it will call a NEW PAGE...
Hope it helps!!
Regards,
Pavan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.