cancel
Showing results for 
Search instead for 
Did you mean: 

focus from one application to another application

Former Member
0 Kudos

Hello,

I have a problem with a focusing on a portal.

There are two independent Web Dynpro Java Applications on one portal page. If you first took action in the lower application and then continue your work in the upper application the focus jumps back into the lower application after every click in the upper app. You have to scroll every time to get back to the upper app.

The portal attribute <Isolationmethod> didnu2019t work. Using u2018URLu2019 as attribute value lead to time-killing page-reloading at every action.

Iu2019m really in despair and need a solution badly.

Best regards,

Nils

Accepted Solutions (0)

Answers (1)

Answers (1)

dao_ha
Active Contributor
0 Kudos

Hi Nils,

Please provide more details about your Portal, WDJ, Windows, internet browser versions. Do these 2 independent WDJ apps need to be on the same portal page and opened at the same time (what if user open another browser session to use these apps separately)? Check the set focus in the upper app. Looks like the lower app always has the control (so it tries to get back to where it was left off).

Hope it helps.

Dao

Former Member
0 Kudos

Hi Dao,

I wish you a happy new year.

Now to your questions.

Version of:

Portal: 7.00 SP22

WDJ: 7.00 SP22

Windows: XP (Citrx Farm)

Internet Explorer: MS IE 7

No the 2 WDJ apps must be in the same page. Yes you are right, it looks like the lower app has the control. My question is: what can I do to get the focus back from the lower app to the upper app.

Thanks

Nils

dao_ha
Active Contributor
0 Kudos

Hi Nils,

Thanks and Happy New Year to you too.

As I suggested earlier, can you check to see if the upper app has the proper set focus? Is it possible to have each of these 2 apps opens its own separate window (instead of having both running in the same window)? That way, when user switch windows, they should be back to where it was left off in each of these apps, hopefully

Dao

Former Member
0 Kudos

Hi Nils,

We have to follow below steps for focus.

1. Create an input field with width 0px and bind an attribute say Va_MessageFocus in upper view.

2. Create a method in the upper view and paste the below code in that method.

if(!wdComponentAPI.getMessageManager().isEmpty()){

wdThis.wdGetAPI().requestFocus(wdContext.currentContextElement(),

wdContext.getNodeInfo().getAttribute(wdContext.currentContextElement().VA__MESSAGE_FOCUS));

}

3. Now call this method in WdDoModifyView() method of upperview.

Please try and let me know if u still face any issue.

With Regards,

Ramesh G.

Edited by: Ramesh Ganasala on Jan 5, 2012 11:35 AM

Former Member
0 Kudos

Hi Ramesh,

thanks for your steps...I try it but the solution is the same the focus is on the upper apps. I have in the upper apps a table with a treebynestingtablecolumn. The focus is alway on the mastecolumn and that is my problem.

With regards,

Nils

Former Member
0 Kudos

Hi Nils,

Please try this way.

1. In lower appl create a duplicate UI containing the performed action.

2. Create two visible type attributes and set it to the two duplicate UI's.

3. On screen load of the application set the visibility as visible for 1 UI element and NONE to another element.

3. On action of the action again follow the same procedure.

4. Now it should work. PFB the code which you have to write on action of the action.

if(null!=wdContext.currentVn_AccessControlElement().getVa_Bt_WsScreen_Visiblity()&&

"VISIBLE".equalsIgnoreCase(wdContext.currentVn_AccessControlElement().getVa_Bt_WsScreen_Visiblity().toString())){

wdContext.currentVn_AccessControlElement().setVa_Bt_WsScreen_Visiblity(WDVisibility.NONE);

wdContext.currentVn_AccessControlElement().setVa_Bt_WsScreen_Visiblity_1(WDVisibility.VISIBLE);

} else if(null!=wdContext.currentVn_AccessControlElement().getVa_Bt_WsScreen_Visiblity_1()&&

"VISIBLE".equalsIgnoreCase(wdContext.currentVn_AccessControlElement().getVa_Bt_WsScreen_Visiblity_1().toString())){

wdContext.currentVn_AccessControlElement().setVa_Bt_WsScreen_Visiblity_1(WDVisibility.NONE);

wdContext.currentVn_AccessControlElement().setVa_Bt_WsScreen_Visiblity(WDVisibility.VISIBLE);

}

Please reply me if you still facing issue.

With Regards,

Ramesh G.