on 11-20-2009 11:32 AM
Hi Experts.
In our applications, there is a button. On click of that button an ALV list will be displayed in the POP-UP.
First time when we click the button this works fine. After that the ALV list does not get displayed in the POU-UP.
Every time we have to re login and do the process.
Note: This is happening only after patching.
Thanks.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
We will need to see your code. I assume there is something wrong with the intialization of the ALV.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi i have attached the piece of code. This code is written in DOINIT Method of the view in which the ALV is embedded. Everytime the table lt_locations will have the data which needs to be displayed in the ALV. The ALV gets displayed only first time and next time if we click the button, the ALV list is not displayed.
DATA lo_nd_srlocations TYPE REF TO if_wd_context_node.
DATA lo_el_srlocations TYPE REF TO if_wd_context_element.
DATA ls_srlocations TYPE wd_this->element_srlocations.
DATA it_srlocations TYPE wd_this->elements_srlocations.
DATA lt_srlocations TYPE STANDARD TABLE OF zxr_locations.
navigate from <CONTEXT> to <SRLOCATIONS> via lead selection
lo_nd_srlocations = wd_context->get_child_node( name = wd_this->wdctx_srlocations ).
get element via lead selection
lo_el_srlocations = lo_nd_srlocations->get_element( ).
SELECT * FROM zxr_locations INTO TABLE lt_srlocations.
DATA lo_nd_locations TYPE REF TO if_wd_context_node.
DATA lo_el_locations TYPE REF TO if_wd_context_element.
DATA ls_locations TYPE wd_this->element_locations.
DATA lt_locations TYPE wd_this->elements_locations.
navigate from <CONTEXT> to <LOCATIONS> via lead selection
lo_nd_locations = wd_context->get_child_node( name = wd_this->wdctx_locations ).
get all declared attributes
lo_nd_locations->get_static_attributes_table(
IMPORTING
table = lt_locations ).
lo_nd_srlocations->bind_table( lt_locations ).
lo_nd_srlocations->bind_table( lt_srlocations ).
DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.
lo_cmp_usage = wd_this->wd_cpuse_alv_srlocations( ).
IF lo_cmp_usage->has_active_component( ) IS INITIAL.
lo_cmp_usage->create_component( ).
ENDIF.
DATA lo_interfacecontroller TYPE REF TO iwci_salv_wd_table .
lo_interfacecontroller = wd_this->wd_cpifc_alv_srlocations( ).
DATA lo_value TYPE REF TO cl_salv_wd_config_table.
lo_value = lo_interfacecontroller->get_model(
).
data lr_column_settings type REF TO if_salv_wd_column_settings.
*data lr_table_settings type ref to if_salv_wd_table_settings.
lr_column_settings ?= lo_value.
*lr_table_settings ?= lo_value.
lr_column_settings->delete_column( 'MANDT' ).
Hi,
Always try to instantiate teh ALV based on the action of link or button...
Fr Ex: when you are opening a popup using the button/linktoaction then write the code of instanttion in that handler..rather in DOINIT..
One more, what is the methodof if_wd_window_manager have you used to generate teh popup...
In the code wizardthere is a method to open a popup for a ALV using Component usage..
Hi,
In the code wizard, to open a popup for a ALV using Component usage
press CTRL+ F7..
Select generate Popup
Component Use ALV_TABLE "GIVE THE ALV COMP NAME
Window Name TABLE.
CODE IS GENERATED AS BELOW:
data lo_window_manager type ref to if_wd_window_manager.
data lo_api_component type ref to if_wd_component.
data lo_window type ref to if_wd_window.
lo_api_component = wd_comp_controller->wd_get_api( ).
lo_window_manager = lo_api_component->get_window_manager( ).
lo_window = lo_window_manager->create_window_for_cmp_usage(
interface_view_name = 'TABLE'
component_usage_name = 'ALV_TABLE'
title =
close_in_any_case = abap_true
message_display_mode = if_wd_window=>co_msg_display_mode_selected
).
lo_window->open( ).
Priya
Hi Priya,
I tried the method which u suggested, but still it does not work.
The same issue. For the first time the ALV table gets displayed and rest of the times the ALV table does not get displayed.
This looks like a pure patching issue as until yesterday the problem was not there is production but after applying patch upgrade in Prod we are facing the similar issue there as well. We have not moved any additional changes to prod in recent time.
Can any one of you guys suggest any SAP note for the same.
hi,
Try this :
Go to View in which ALV view is embedded- > Properties Tab.
Try changing the Lifetime Property of View to When visible from Framwork controlled.
See if it helps.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
After patch, I have created one more application in addtion to the current for the compoennt and teste it out....
If this still doesnot work, then copy the whole compoennet and create a new application for this copied one...
This should work...
if this stil deosnot work then paste your code on opening a popup in ALV....
Regards,
Lekha.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
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.