Skip to Content
author's profile photo Former Member
Former Member

What is the report writing tool

Hi all,

What is the report writing tool ?

How it helps to abapers ?

send me any useful links on same ?

Thanks in advance

Krupali

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Posted on Jun 19, 2008 at 05:24 AM

    se38

    in this transaction u can write report programs....

    Edited by: Rudra Prasanna Mohapatra on Jun 19, 2008 7:24 AM

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Jun 19, 2008 at 05:24 AM

    Hi ,

    Report Writing tools( se38 / se80) used to write the report...

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jun 19, 2008 at 05:28 AM

    dear friend

    SE38 and SE84 are the tool in sap

    where u can write you abap progarm.

    as example i am giving....:

    &----


    *& Report Y_SD_PRE_SHIPMENT

    *&

    &----


    *&

    *&

    &----


    REPORT y_sd_pre_shipment.

    **************DATA DECLARATION****************************************

    DATA : BEGIN OF i_vbrk OCCURS 0,

    vbeln TYPE vbrp-vbeln,

    END OF i_vbrk.

    DATA: prog TYPE sy-repid,

    dynnr TYPE sy-dynnr,

    FNAM TYPE RS38L_FNAM,

    v_vbeln type ZSDTANNXINV-vbeln,

    idx type i,

    cnt type i.

    DATA: I_FINAL TYPE TABLE OF YPSHIP,

    W_FINAL TYPE YPSHIP.

    DATA: I_HEAD TYPE TABLE OF YPSHIP1,

    W_HEAD TYPE YPSHIP1.

    ************************************************************************

    DATA: it_otf TYPE STANDARD TABLE OF itcoo,

    it_docs TYPE STANDARD TABLE OF docs,

    it_lines TYPE STANDARD TABLE OF tline,

    st_job_output_info TYPE ssfcrescl,

    st_document_output_info TYPE ssfcrespd,

    st_job_output_options TYPE ssfcresop,

    st_output_options TYPE ssfcompop,

    st_control_parameters TYPE ssfctrlop,

    v_len_in TYPE so_obj_len,

    v_language TYPE sflangu VALUE 'E',

    v_e_devtype TYPE rspoptype,

    v_bin_filesize TYPE i,

    v_name TYPE string,

    v_path TYPE string,

    v_fullpath TYPE string,

    v_filter TYPE string,

    v_uact TYPE i,

    v_guiobj TYPE REF TO cl_gui_frontend_services,

    v_filename TYPE string.

    ****************************************************************

    ******USER INTERACTION OPTION FOR THE INVOICE NO

    ****************************************************************

    SELECTION-SCREEN : BEGIN OF BLOCK b1 WITH FRAME TITLE r.

    PARAMETERS: invoice LIKE ZSDTANNXINV-vbeln obligatory .

    SELECTION-SCREEN : END OF BLOCK b1.

    *********************************************************************

    *********************************************************************

    AT SELECTION-SCREEN ON VALUE-REQUEST FOR invoice.

    REFRESH i_vbrk.

    SELECT vbeln FROM vbrk INTO TABLE i_vbrk.

    IF sy-subrc IS INITIAL.

    prog = sy-repid.

    dynnr = sy-dynnr.

    CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'

    EXPORTING

    • DDIC_STRUCTURE = ' '

    retfield = 'VBELN'

    dynpprog = prog

    dynpnr = dynnr

    dynprofield = 'INVOICE'

    value_org = 'S'

    TABLES

    value_tab = i_vbrk.

    • FIELD_TAB =

    • RETURN_TAB =

    • DYNPFLD_MAPPING =

    • exceptions

    • parameter_error = 1

    • no_values_found = 2

    • others = 3

    IF sy-subrc <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    ENDIF.

    ENDIF.

    *************************************************************************

    at selection-screen on invoice.

    if invoice is not initial.

    clear v_vbeln.

    select single vbeln from ZSDTANNXINV into v_vbeln where vbeln = invoice.

    if sy-subrc is not initial.

    message 'Enter Valid Document No' type 'E'.

    endif.

    endif.

    *************************************************************************

    START-OF-SELECTION.

    perform get_data.

    perform process_data.

    &----


    *& Form get_data

    &----


    • text

    ----


    • --> p1 text

    • <-- p2 text

    ----


    form get_data .

    IF INVOICE IS NOT INITIAL.

    SELECT VBELN

    VTEXT

    NETWT

    GROSSWT

    vsslname

    kindofpack

    INCO1

    INCO2

    REMDATE

    DESTINATION

    SHPNGLIN1

    CNTRNO

    TRAILERNO1

    ETDDATE

    ETADATE

    baanr

    FROM ZSDTANNXINV

    INTO TABLE I_HEAD

    WHERE VBELN = INVOICE.

    ENDIF.

    IF I_HEAD[] IS NOT INITIAL.

    select vbeln

    POSNR

    MATNR

    MAKTX

    meins

    RATE

    VALUE

    WAERK

    PRPOSNR

    from zsafii

    into corresponding fields of table i_final

    for all entries in i_head

    where vbeln = i_head-vbeln.

    ENDIF.

    describe table i_final lines cnt.

    idx = 1.

    loop at i_final into w_final.

    if idx le cnt.

    read table i_head into w_head with key vbeln = w_final-vbeln.

    if sy-subrc is initial.

    move-corresponding w_head to w_final.

    modify i_final from w_final index idx.

    idx = idx + 1.

    endif.

    endif.

    endloop.

    endform. " get_data

    &----


    *& Form process_data

    &----


    • text

    ----


    • --> p1 text

    • <-- p2 text

    ----


    form process_data .

    ***********************************************

    CALL FUNCTION 'SSF_GET_DEVICE_TYPE'

    EXPORTING

    i_language = v_language

    i_application = 'SAPDEFAULT'

    IMPORTING

    e_devtype = v_e_devtype.

    st_output_options-tdprinter = v_e_devtype.

    *st_output_options-tdprinter = 'locl'.

    st_control_parameters-no_dialog = 'X'.

    st_control_parameters-getotf = 'X'.

    ***************************************************

    sort i_final by vbeln.

    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'

    EXPORTING

    formname = 'Y_SSF_PRESHIPMENT'

    • VARIANT = ' '

    • DIRECT_CALL = ' '

    IMPORTING

    FM_NAME = FNAM

    • EXCEPTIONS

    • NO_FORM = 1

    • NO_FUNCTION_MODULE = 2

    • OTHERS = 3

    .

    IF sy-subrc <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    ENDIF.

    if fnam is not initial.

    CALL FUNCTION FNAM

    EXPORTING

    • ARCHIVE_INDEX =

    • ARCHIVE_INDEX_TAB =

    • ARCHIVE_PARAMETERS =

    CONTROL_PARAMETERS = st_control_parameters

    • MAIL_APPL_OBJ =

    • MAIL_RECIPIENT =

    • MAIL_SENDER =

    OUTPUT_OPTIONS = st_output_options

    • USER_SETTINGS = 'X'

    IMPORTING

    DOCUMENT_OUTPUT_INFO = st_document_output_info

    JOB_OUTPUT_INFO = st_job_output_info

    JOB_OUTPUT_OPTIONS = st_job_output_options

    TABLES

    itab = I_FINAL

    i_head = I_HEAD

    • EXCEPTIONS

    • FORMATTING_ERROR = 1

    • INTERNAL_ERROR = 2

    • SEND_ERROR = 3

    • USER_CANCELED = 4

    • OTHERS = 5

    .

    IF sy-subrc <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    ENDIF.

    ******************************************************************************

    .........................CONVERT TO OTF TO PDF.......................

    CALL FUNCTION 'CONVERT_OTF_2_PDF'

    IMPORTING

    bin_filesize = v_bin_filesize

    TABLES

    otf = st_job_output_info-otfdata

    doctab_archive = it_docs

    lines = it_lines

    EXCEPTIONS

    err_conv_not_possible = 1

    err_otf_mc_noendmarker = 2

    OTHERS = 3.

    IF sy-subrc <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    ENDIF.

    ........................GET THE FILE NAME TO STORE....................

    CONCATENATE 'smrt' '.pdf' INTO v_name.

    CREATE OBJECT v_guiobj.

    CALL METHOD v_guiobj->file_save_dialog

    EXPORTING

    default_extension = 'pdf'

    default_file_name = v_name

    file_filter = v_filter

    CHANGING

    filename = v_name

    path = v_path

    fullpath = v_fullpath

    user_action = v_uact.

    IF v_uact = v_guiobj->action_cancel.

    EXIT.

    ENDIF.

    ..................................DOWNLOAD AS FILE....................

    MOVE v_fullpath TO v_filename.

    CALL FUNCTION 'GUI_DOWNLOAD'

    EXPORTING

    bin_filesize = v_bin_filesize

    filename = v_filename

    filetype = 'BIN'

    TABLES

    data_tab = it_lines

    EXCEPTIONS

    file_write_error = 1

    no_batch = 2

    gui_refuse_filetransfer = 3

    invalid_type = 4

    no_authority = 5

    unknown_error = 6

    header_not_allowed = 7

    separator_not_allowed = 8

    filesize_not_allowed = 9

    header_too_long = 10

    dp_error_create = 11

    dp_error_send = 12

    dp_error_write = 13

    unknown_dp_error = 14

    access_denied = 15

    dp_out_of_memory = 16

    disk_full = 17

    dp_timeout = 18

    file_not_found = 19

    dataprovider_exception = 20

    control_flush_error = 21

    OTHERS = 22.

    IF sy-subrc <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    ENDIF.

    ENDIF.

    ********************************************************************8

    endform. " process_data

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.