Application Development 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: 

need help for displaying month format

Former Member
0 Kudos
84

this my input screen

Documenttype fromdate todate

invoice 01/12/2003 02/19/2003

now i am getting output as

invoice feb total

invoice jan total

i want chage the output screen as

doctype feb jan febtotal jantotal

invoice 5 6 4564 5454

ca u help how to do the coding

5 REPLIES 5

Former Member
0 Kudos
48

Hi,

Are you using WRITE statement or ALV to display the report..

Thanks,

Naren

0 Kudos
48

yes

0 Kudos
48

alv to display the report

Former Member
0 Kudos
48

Dear This is the one of sample how to get month in character

try with this otherwise

send your rquirment again

REPORT ZEXAMPLE.

DATA: BEGIN OF MONTH_NAMES OCCURS 0.

INCLUDE STRUCTURE T247.

DATA: END OF MONTH_NAMES.

DATA: V_LASTDAY LIKE SY-DATUM,

V_NEXTMONTH LIKE SY-DATUM,

V_DAYTXT(15).

CALL FUNCTION 'MONTH_NAMES_GET'

EXPORTING

LANGUAGE = SY-LANGU

TABLES

MONTH_NAMES = MONTH_NAMES

EXCEPTIONS

MONTH_NAMES_NOT_FOUND = 1

OTHERS = 2.

CALL FUNCTION 'RP_LAST_DAY_OF_MONTHS'

EXPORTING

DAY_IN = SY-DATUM

IMPORTING

LAST_DAY_OF_MONTH = V_LASTDAY.

CALL FUNCTION 'RH_GET_DATE_DAYNAME'

EXPORTING

LANGU = SY-LANGU

DATE = V_LASTDAY

IMPORTING

DAYTXT = V_DAYTXT.

READ TABLE MONTH_NAMES WITH KEY MNR = SY-DATUM+4(2).

WRITE:/'THE LAST DAY OF', MONTH_NAMES-LTX, 'IS THE', V_LASTDAY, 'WHICH IS A', V_DAYTXT.

CALL FUNCTION 'MONTH_PLUS_DETERMINE'

EXPORTING

MONTHS = '1'

OLDDATE = SY-DATUM

IMPORTING

NEWDATE = V_NEXTMONTH.

READ TABLE MONTH_NAMES WITH KEY MNR = V_NEXTMONTH+4(2).

WRITE:/'NEXT MONTH IS', MONTH_NAMES-LTX.

CALL FUNCTION 'RE_ADD_MONTH_TO_DATE'

EXPORTING

MONTHS = '1'

OLDDATE = V_NEXTMONTH

IMPORTING

NEWDATE = V_NEXTMONTH.

READ TABLE MONTH_NAMES WITH KEY MNR = V_NEXTMONTH+4(2).

WRITE:/'THE MONTH AFTER THAT IS', MONTH_NAMES-LTX.

Reqards if Helpful

0 Kudos
48

hi,

my input screen will

date from (4/29/2003) to (6/29/2003)

customer siva kumar

i have three radio button

my out put screen should be like this

<b> documenttype june(tomonth) may(month2) (junemonth3) totjune

invoice 45 34 44 5435</b>(output page should be like this

i should print like this first i should display to date(6/29/2003),may, june(4/29/2003)