on 11-17-2008 4:48 PM
hi
I add a date_navigotor on my page
how can i learn selected day and week and i 'm click week number error message :
" Parameter NODE contains an invalid value "
thanks .
your answer thanks .
i define a node it's name daten and a attribute it's name date and type datum
and Bind the firstSelectedDate property to daten node
but error message: Adapter error in &VIEW_ELEMENT_TYPE& "DATE_NAVIGATOR" of view "YDND_WDPP033807.PANEL": Context binding of property FIRST_SELECTED_DATE cannot be resolved: PANEL.1.DATEN absent.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Follow these steps,
1- Create date navigator
2- create a attribute in some view context as data type first_Date suppose... and provide the data type as datum
3- Go to the view and click on the properties of date navigator
4- Bind the firstSelectedDate property to first_Date attribute
5- create an event handler for week (onWeekSelect). So in the method write the below code.(change the code as per ur data declaration)
DATA lo_nd_flag1 TYPE REF TO if_wd_context_node.
DATA lo_el_flag1 TYPE REF TO if_wd_context_element.
DATA ls_flag1 TYPE wd_this->element_flag1.
DATA lv_date LIKE ls_flag1-date.
* navigate from <CONTEXT> to <FLAG1> via lead selection
lo_nd_flag1 = wd_context->get_child_node( name = wd_this->wdctx_flag1 ).
* get element via lead selection
lo_el_flag1 = lo_nd_flag1->get_element( ).
* get single attribute
lo_el_flag1->get_attribute(
EXPORTING
name = `DATE`
IMPORTING
value = lv_date ).
Here my context attribute name is 'date'.
Now in lv_Date variable you have the selected date.
Now call this FM to get the week of selected date.
GET_WEEK_INFO_BASED_ON_DATE
and pass lv_date as importing paramters. you will get the week number.
Hope it works.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
8 | |
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.