cancel
Showing results for 
Search instead for 
Did you mean: 

Call VF03 transaction to display the details of invoice selected in alv

Former Member
0 Kudos

Hi experts,

I have an ALV in my web dynpro screen and it contains invoice number in one of the column.

My requirement is,On clicking my invoice number in alv table, It has to open the transaction VF03 with the selected invoice number (Display the invoice details of that invoice number selected in alv).

Can someone please explain how to achieve this.

Thanks,

Delphi.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Thanks all.

I have solved the issue by referring the thread below.

Thanks,

Delphi.

Former Member
0 Kudos

Hi Delphi,

Can you please suggest me how you are passing the values into the VF03 transaction. Please suggest.

Former Member
0 Kudos

Hi,

To get the host and port use the below code

DATA :

url TYPE string,

host TYPE string,

port TYPE string.

*Call below method to get host and port

cl_http_server=>if_http_server~get_location(

IMPORTING host = host

port = port ).

To get the invoice number which is clicked in ALV, use below code

FIELD-SYMBOLS: <l_value> TYPE ANY.

ASSIGN r_param->value->* TO <l_value>.

  • URL to pass

CONCATENATE

'HTTP://'

host

':'

port

'/SAP/BC/GUI/SAP/ITS/WEBGUI?~transaction=*VF03 VBRK-VBELN='

<l_value>

INTO

url.

To open the Transaction in separate window use below code

DATA : lo_window_manager TYPE REF TO if_wd_window_manager,

lo_api_component TYPE REF TO if_wd_component,

lo_window TYPE REF TO if_wd_window.

lo_api_component = wd_comp_controller->wd_get_api( ).

lo_window_manager = lo_api_component->get_window_manager( ).

lo_window_manager->create_external_window(

EXPORTING

url = url

RECEIVING

window = lo_window ).

lo_window->open( ).

It will open the transaction VF03 in separate browser with the details of the invoice number which is clicked from web dynpro screen.

Regards,

Delphi.

Former Member
0 Kudos

Hi Delphi,

Thanks for your reply. Do you have any idea on that we can call custom transactions as well from WD application?

Thanks

Sanket

former_member187452
Contributor
0 Kudos

Hi,

check this link.

Regards,

Bharat

Former Member
0 Kudos

Hi thanks for ur reply. currently how am opening the transaction is, i am using the method create_external_window by passing the url as "http:://servername/GUI/SAP/ITS/WEBGUI?~TRANSACTION=VF03'

By this way its opening the VF03 but the problem here is am not able to pass my invoice number which i selected in alv from web dynpro.

Please help me to proceed further??

Former Member
0 Kudos

Hi

Since the HTTP plugin session and the ABAPGUI session are 2 separate entities , you cannot call gui stuff thro the web.

1. Option is to use shared memory using CL_SHM_AREA

2. Create a SAP shortcut and then use the cl_wd_runtime_services to attach this to the runtime.

just search the forums fr this class. Now you use class CL_BSP_SERVER_COOKIE to set a cookie and then read the cookie to get the invoice no in your z report which will read the cookie and call tcode VF03 SKIPPING INITIAL SCREEN

I don't know if there is any other approach , since you cannot call gui thro the web , May want to try calling vf03 in a function module starting new task if your calling ur app in a gui using CL_GUI_HTML_VIEWER.