on 05-13-2007 5:53 PM
Hi
I have an UI DropDown by Key bound to a SVS.
How can i clear the selected value. i.e. making it blank again.
Properties of the node are as follows:
Carinality: 1....n
Lead Selection: True
Selection: 0...n
Singleton: True
Posts earlier on the similar issue are of no help to me.
and I can not use DropDown by Index.
Value chosen in DropDown form one of the criterion for search / input in RFC.
So i can not use -1 as one more enumeration.
Please help.
Regards
Vineet Vikram
vineet,
Just set corresponding attribute to null -- attribute to which DropDownByKey.SelectedKey is bound.
wdContext.current<NodeName>Element().set<AttributeName>(null);
Valery Silaev
SaM Solutions
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear Valery
I think some gap is left in explaining the problem.
The problem is not getting the drop down blank.
It is about clearing the selection.
Once the user selects a value from the DropDown, then he can not clear it.
He has to choose one of the values in the dropdown.
I want to give the provision in which the user will be able to do away with the drop down even if once he used it i.e. passing no value from the dropdown.
I hope i have stated my problem quite clearly this time.
Waiting for your response.
Vineet Vikram
Hi Vineet,
In your code for populating values in DDBK
IWDMessageManager mgr = wdComponentAPI.getMessageManager();
IWDAttributeInfo atrInfo = wdContext.node<Your Node>().getNodeInfo().getAttribute("attribute mapped to selectedKey property");
IModifiableSimpleValueSet ValueSet = atrInfo.getModifiableSimpleType().getSVServices().getModifiableSimpleValueSet();
// add a default value to valueSet
ValueSet.put("Default","Select a value");
int Nodesize = wdContext.node<your node>().size();
for(int i = 0; i < wdContext.node<Your node>().size();i++)
{
// code for populating values in value set
}
After the user has chosen a value from DDBK and invoked some action,
in the view implementaion of UI before returning to the view again add this
line of code
wdContext.current<node>Element().set<attribute mapped to selectedKey property>("Default");
This will set the DDBK value to default every time the action is completed.
Hello ,
I am on EP7.0 ERP05 NW04s and trying to modify the ESS Banks Detail screen in which I want the Payment Method Dropdown to list only Direct Deposit and Payroll Check and leave the rest....how can I filter these values.?
Any help would be highly appreciated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vineet,
Please correct me if my understanding of the problem.You have a dropdownbyKey
now you want the selection of the dropdown to get cleared i.e set to some default value that you can filter.
If this is your problem then I would suggest the following solution to it:
I think you must be aware of the fact that the key of the value selected gets stored in the attribute if u aware with the binding of the key of this dropdown.You can certainly write an action that will do this for you.All you need is to set the attribute to the default key and dropdown will automatically have the changes reflected at runtime.
Regards
Amit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.