on 09-16-2008 8:27 AM
hello ,
I have to print a cheque in which which i m getting date in 16.09.2008 format
but i want these dates to be printed in boxes of the cheque like 16 in first box
09 in second box...
how can i do it?
thanks and regards
Hi Anshul dave,
From Script use Perform and EndForm ... take date in to Form (different program) then set three variables in which Date, Month and Year is sent to script again.
Do you know how to use Perform and EndForm..using ITCSY structure.
Any doubts revert me back
Regards,
sg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi anshul dave,
Try this...if not let me know your ID could send you screen shots....
let say in script the date is Script_date...
then in Script Window where your are print the date...
*Write In Script
PERFORM SEPARATE_DATE ZPROGRAM USING &SCRIPT_DATE&
CHANGING &DATE&
CHANGING &MONTH&
CHANGING &YEAR&
ENDPERFORM
*Write In ZPROGRAM
FORM SEPARATE_DATE tbl_input structure itcsy "structure
tbl_output structure itcsy.
data: v_date(2) type n,
v_month(2) type n,
v_year(4) type n,
v_totdate type string.
Get Date from Script
read table tbl_input with key 'SCRIPT_DATE'.
check sy-subrc = 0.
v_totdate = tbl_input-value.
split v_totdate at '.' into v_date v_month v_year.
*check how its getting read in debugging mode.
loop at tbl_output.
case tbl_output-name.
when 'DATE'.
tbl_output-value = v_date.
modify tbl_output.
when 'MONTH'.
tbl_output-value = v_month.
modify tbl_output.
when 'YEAR'.
tbl_output-value = v_year.
modify tbl_output.
endcase.
endloop.
ENDFORM.
Regards,
sg
Hi,
u can use split at syntax.
get day,month ,year separately and then print it in boxes .
Split zdate at '.'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.