Application Development and Automation 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: 
Read only

reports

Former Member
0 Likes
770

hi guyz

i want know in detail about how we will call"transaction code in a report"

thank you

suneel erk

7 REPLIES 7
Read only

Former Member
0 Likes
748

You can use

CALL TRANSACTION 'T-CODE'.

Regards

Kathirvel

Read only

RichHeilman
Developer Advocate
Developer Advocate
0 Likes
748

You can simply use the CALL TRANSACTION 'SM50' statement at anytime. You can set parmeter id first then call the transaction.

For example, if you wanted to call VA03 with a sales docuement number....

set parameter id 'AUN' field '12345'.

call transaction 'VA03' and skip first screen.

Regards,.

Rich Heilman

Read only

0 Likes
748

can u give me example...coding....

Read only

0 Likes
748


report zrich_0001.

data: ivbak type table of vbak with header line.

start-of-selection.


  select * into table ivbak from vbak
                up to 10 rows.

  loop at ivbak.
    format hotspot on.
    write:/ ivbak-vbeln.
    hide ivbak-vbeln.
    format hotspot off.
  endloop.


at line-selection.

  set parameter id 'AUN' field ivbak-vbeln.
  call transaction 'VA03' and skip first screen.

Regards,

Rich Heilman

Read only

Former Member
0 Likes
748

Here is a BDC using CALL TRANSCATION

http://www.sapdevelopment.co.uk/bdc/bdc_ctcode.htm

Interactive List with CALL TRANSACTION

REPORT ZTETS_CURSOR .

DATA: FIELD(20),

VALUE(10).

DATA: BEGIN OF ITAB OCCURS 0,

VBELN LIKE VBAK-VBELN,

POSNR LIKE VBAP-POSNR,

END OF ITAB.

SELECT VBELN

POSNR

FROM VBAP

UP TO 100 ROWS

INTO TABLE ITAB.

TOP-OF-PAGE.

WRITE:(10) 'VBELN',

(6) 'POSNR'.

END-OF-SELECTION.

LOOP AT ITAB.

WRITE: /(10) ITAB-VBELN,

(6) ITAB-POSNR.

ENDLOOP.

AT LINE-SELECTION.

GET CURSOR FIELD FIELD VALUE VALUE.

IF FIELD = 'ITAB-VBELN'.

CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'

EXPORTING

INPUT = VALUE

IMPORTING

OUTPUT = VALUE.

SET PARAMETER ID 'AUN' FIELD VALUE.

CALL TRANSACTION 'VA02' AND SKIP FIRST SCREEN.

ENDIF.

Regards

Kathirvel

Read only

Former Member
0 Likes
748

Hi,

say if you have a po number and you want to go to the corresponding po,

YOU CAN SEE THE PARAMTER ID BES FOR DATA ELEMENT EBELN

SO GET THE PARAMETR ID FOR FIELD AND PASS IT IN PLACE OF BES.

SET PARAMETER ID 'BES' FIELD itab-PONUMBER.

CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN.

Thanks

venki

Read only

Former Member
0 Likes
748

hi,

thanks,but i don't know how to get the parameter id for the field.

say eg: BES for EBELN.please guide me.