on 05-09-2008 1:59 AM
Hi Experts,
In my ALV output table i want to put a link for one column so that when user click on that link it'll call another view of the same applications .Please remember the output is on ALV not in any table .
Please give me solution.
Regards,
Satya
Hi,
*alv
DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.
lo_cmp_usage = wd_this->wd_cpuse_usage_alv_logs( ).
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_usage_alv_logs( ).
DATA lv_value TYPE REF TO cl_salv_wd_config_table.
lv_value = lo_interfacecontroller->get_model( ).
DATA: lr_column TYPE REF TO cl_salv_wd_column.
lr_column = lv_value->if_salv_wd_column_settings~get_column( 'APPLICATIONLOG').
Display link in column connid
DATA: lr_link TYPE REF TO cl_salv_wd_uie_link_to_action.
lr_column = lv_value->if_salv_wd_column_settings~get_column( 'APPLICATIONLOG' ).
CREATE OBJECT lr_link.
lr_link->set_text_fieldname( 'APPLICATIONLOG' ).
lr_column->set_cell_editor( lr_link ).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If you are using the ALV, then you have first create a event handler of event type ON_CLICK. And inside the event hadler u have to write the code to call the other WD Applicatiom.
IF you are calling through OBN in the poral then here is the code
l_api_component = wd_comp_controller->wd_get_api( ).
l_portal_manager = l_api_component->get_portal_manager( ).
if r_param->COLUMN = 'SALE_ORDER'.
CALL METHOD l_portal_manager->navigate_to_object
EXPORTING
system = 'SAP_R3'
object_type = 'com.amd.obn.so'
operation = 'SALESORDER'
business_parameters = lt_params
USE_FORWARDPARAMETERS_OF_AL = abap_true.
ELSE.
CALL METHOD l_portal_manager->navigate_to_object
EXPORTING
system = 'SAP_R3'
object_type = 'com.amd.obn.ship'
operation = 'SHIPMENT'
business_parameters = lt_params
FORWARD_OBN_METADATA = ABAP_TRUE
USE_FORWARDPARAMETERS_OF_AL = ABAP_TRUE.
ENDIF.
.
Regards,
Satya
Hi
check this code to add a link to action on a column of alv table.
first instantiate the alv component
create an attribute r_table ref to CL_SALV_WD_CONFIG_TABLE in the attributes tab.
data: lv_action type ref to cl_salv_wd_uie_link_to_action.
DATA: lr_column TYPE REF TO cl_salv_wd_column,
lr_function TYPE REF TO cl_salv_wd_function.
data:
lr_functions type ref to if_salv_wd_function_settings.
lr_functions ?= wd_this->r_table.
lr_function = lr_functions->create_function( 'MYLINKTOACTION' ).
lr_column = lo_config_model_value->if_salv_wd_column_settings~get_column( 'FLDATE' ).
CREATE OBJECT lv_action.
lv_action->set_text_fieldname( 'FLDATE' ).
lr_column->set_cell_editor( lv_action ).
create a method of type with name MYLINKTOACTION selecting the event as "on cell action".
and write the code in this method.
u can refer to standard package salv_wd_test.
in that check the component SALV_WD_TEST_TABLE_TOOLBR
regards
chythanya
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.