on 06-03-2008 2:25 PM
Dear All,
I have a table , in which if one of the fields (inputfield) is changed, then on the onEnter event, another filed in the same row of the table should be updated.
However, when the inputfiled is selected for updation the corresponding row is not selected as the lead selection.
So the field of another row which is the lead selected one, gets updated.
How do I solve this problem?
Thanks and regards,
Mayuresh
Hi,
Create a paramter to the onAction of type IWDNodeElement or <Iprivate>your Node element.
Then map the paramter to the action using the following code in wdDomodify
if(firstTime)
{
IWDInputField inputField = (IWDInputField)view.getElement("<Your input field>");
//Create a parameter of type IWDNodeElement and name it as "nodeElement"
inputField.mappingOfOnEnter().addSourceMapping("nodeElement", "nodeElement");
}
Now your onEnter action should look some what similar to the following
public void onActionOnEnter(com.sap.tc.webdynpro.progmodel.api.IWDCustomEvent wdEvent, com.sap.tc.webdynpro.progmodel.api.IWDNodeElement nodeElement )
{
//@@begin onActionOnEnter(ServerEvent)
//Access your attribute lets say Name as follows
String name = (String)nodeElement.getAttributeValue("Name");
//Assigning to the other attribute which is bound to other field
nodeElement.setAttributeValue("OtherField", name);
//@@end
}
If you are working with CE you can use paramter instead of the code in the wdDomodify part.
Regards
Ayyapparaj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Thanks for the replies.
If you are working with CE you can use paramter instead of the code in the wdDomodify part.
I am working with CE.
How do I use parameter without coding in WDModify?
There is also another way without any coding. Change the table property "compatibilityMode"
I didn't find the compatibilityMode property for the table.
Thanks and regards,
Mayuresh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Above solution certainly works. There is also another way without any coding. Change the table property "compatibilityMode"
Cheers,
~kranthi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
on the OnActionEnter Event just check for the LeadSelection is zero, then Update the other field of the row.
venkat
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
101 | |
13 | |
13 | |
11 | |
11 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.