cancel
Showing results for 
Search instead for 
Did you mean: 

select option value passing between views

Former Member
0 Kudos

hi experts

i have 2 views in my component . First view is the selection screen in that i used select-option component for date .

the enter date is should get in second view . in the first view i am geting the date range in a field symbol <fs_date>

then i bind the <fs_date > to the node attribute with type : date type ref to data .

in first view my code is

CALL METHOD LO_ND_SELECT_OPT->BIND_TABLE

EXPORTING

NEW_ITEMS = <FS_DATE>

  • SET_INITIAL_ELEMENTS = ABAP_TRUE

  • INDEX =

in <FS_DATE> i am having the value . but it not reflecting in the second view when i am retriving it from the node .

in second view i am trying to get that value like this

lo_el_select_opt->get_attribute(

EXPORTING

name = `DATE`

IMPORTING

value = lv_date ).

lv_date is not returning any thing .. i want the range table so that i can use it in select query .

thanks & regards

chinnaiya . P

Accepted Solutions (0)

Answers (3)

Answers (3)

former_member628395
Active Participant
0 Kudos

Hi,

Check if there is a proper mapping of the component controller attribute / node to that in both the views.

If this is done, try reading the node, from which you want the data in the next view, into an internal table, check if you get data in it.

If you get data in the internal table check the initialization lead selection property of the node.

Also if you get data in the internal table, you can read it in a work area and use it.

Regards,

Sagar

Former Member
0 Kudos

hi,

always when there is a need to reuse the field data instead of usng Local controller(view) use global one ..

regards,

Kranthi.

Former Member
0 Kudos

Hi,

In your second view, when you are fetching a particular attribute, make a read on whole table rather than a particular attribute,

you might not be getting any value as lead selection may not be set.

Regards

Manas Dua

Former Member
0 Kudos

HI,

Did you create the local node at the the view ?? or you have create the node at component level ?? If you create a node at view level., in that case you will not be ale to get the data from another view. Also please check the context mapping.

Regards

Satrajit.