cancel
Showing results for 
Search instead for 
Did you mean: 

open a link in same window using webdynpro abap

Former Member
0 Kudos

Hi all ,kindly tell me how to open a new link in the

same window through onclick in web dynpro abap......

Accepted Solutions (1)

Accepted Solutions (1)

abhimanyu_lagishetti7
Active Contributor
0 Kudos

Hi

can you paste your code, how you are achieving this

Create_External_window always creates a new window, you have to use Exit Plug of the window to achieve this

http://help.sap.com/saphelp_nw04s/helpdata/en/45/1bc575ba064574e10000000a114a6b/content.htm

Abhi

Former Member
0 Kudos

hi frnd,

i am new to this functionality can u plz guide me

the steps to perform this with sample codes????

by

ranjith

abhimanyu_lagishetti7
Active Contributor
0 Kudos

go to your window and in outbound plugs tab create an Exit Plug

now go to your View and in Properties tab add your window controller

in the event handler code the following

data: L_REF_MAIN_WINDOW type ref to IG_MAIN_WINDOW .

L_REF_MAIN_WINDOW = WD_THIS->GET_MAIN_WINDOW_CTR( ).

L_REF_MAIN_WINDOW->FIRE_MY_EXIT_PLUG_PLG(

URL = 'http://www.sap.com' " String

).

Abhi

Edited by: Abhimanyu Lagishetti on Jun 24, 2008 12:20 PM

Former Member
0 Kudos

hai abimanyu,

Thanks for ur reply,

I have already got this but i am not able to know where

to use the coding bcz it contains two onactions.

Can u plz guide me for that???

abhimanyu_lagishetti7
Active Contributor
0 Kudos

Hi

2 onActions? i didn't get this.

create a context attribute type string in the Cotnext

you goto the properties section of the LinkToUrl UI element

reference property bind to the context attribute

in WDDOINIT

set the attribute with the url

wd_context->set_attribute( name = '<Attribute_name>' value = "http://sap.com" ).

Abhi

Former Member
0 Kudos

thanks a lot abhi,

The codes works fine , when i click the button the

url link opens in the same window,

But when i click "back" in the browser it doesnt

returns to the main page...and shows "page has expired"

only if i click refresh button it comes to home page.

Can u plz guide me??? what should i do for this abhi???

by

ranjith

abhimanyu_lagishetti7
Active Contributor
0 Kudos

In Web Dynpro you shouldnot use the Browser's Back button, it doesn't work.

where you are navigating ?

you can get back using Suspend and Resume Plugs of Window ( not Exit Plug ),

for this you have to code in the target application

Abhi

Former Member
0 Kudos

Thanks for u again abhi,

Actually my requirement is when i click the button

google home page should be opened, but i want to

return to my WD abap application from google page.

What shall i do for this abhi???

thanks,

ranjith.

abhimanyu_lagishetti7
Active Contributor
0 Kudos

Hi

you can come back to your application by clicking Back button, but the state of the web dynpro application is lost, it will start a new session

It is not possible unless you edit the target application

Abhi

0 Kudos

Thank you !!!!!!!!!!!!!! It´s a very good solution for me.

Answers (0)