on 07-15-2009 12:45 PM
Hi all
I have input field and it already binded context attribute .I am working on enhancement frame work so I can not modify propety of context attribute.My requirement is to create new attribute and bind it with input field dynamically.
I am able to create context attribute and bind it to input field but it's not working ,can we do it dynamically????
Pls help
Regards Reeha
Is the input field created using enhancement framework or is an existing onw? If it is an already exisitng input field and you change its property in enhancement mode, it goes back to the original property once you activate it. Therefore you will need to create a new input field and bind it to the context attribute and also delete the exisitng input field.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
if you already have a context attribute than you can do this, I just created a test application to create one input field and bind it with a context attribute dynamically.
my context is like this:
SUBS_TYPE_NODE <------node name
-SUBS_TYPE_VALUE <----node attribute type string
under WDDOMODIFYVIEW i did this:
if first_time = abap_true.
DATA:
lr_container TYPE REF TO cl_wd_uielement_container,
lr_input TYPE REF TO cl_wd_input_field.
get a pointer to the RootUIElementContainer
lr_container ?= view->get_element( 'ROOTUIELEMENTCONTAINER' )
lr_input = cl_wd_input_field=>new_input_field(
bind_value = 'SUBS_TYPE_NODE.SUBS_TYPE_VALUE' "notice here how I passed the node and its attribute
id = 'INPUT_F1'
view = view ).
cl_wd_matrix_data=>new_matrix_data( element = lr_input ).
lr_container->add_child( lr_input ).
endif.
hope this helps...
AS.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
24 | |
11 | |
9 | |
7 | |
6 | |
5 | |
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.