Skip to Content
0
Former Member
Sep 26, 2005 at 02:50 AM

Problem with context attributes

27 Views

Hello All,

I am currently experiencing some strange behaviour in my WD application so I hope any experts here can give me a hand or spot my mistake.

<u><b>Scenario</b></u>

1) View A is being initialised and by default, will display the name of the manager.

2) This name is being stored as a string attribute "tempName" in a context node of cardinality 1..1.

3) Someone then decides to change the name of the manager in View A but half way, he changes his mind and clicks on a 'cancel button'.

4) This cancel button has an action tagged to it and will then transfer the contents of the attribute "tempName" back to the UI element.

<u><b>Problem</b></u>

The problem that I am experiencing now is that for some strange reason, the name that I stored in "tempName" becomes a NULL whenever it attempts to transfer the contents back to the UI element.

To ensure that tempName is assigned the correct data, I issued a "wdComponentAPI.getMessageManager().reportSuccess("From SearchButton :" + wdContext.currentApproverInfoElement().getPrevious1Name());" so that I know for sure that the correct data is being writtena nd displayed back to me.

Hence, it is very puzzling as I have no idea whatelse may have gone wrong. Any suggestions or feedback will be greatly appreciated. Thank you.

from

Kwok Wei