cancel
Showing results for 
Search instead for 
Did you mean: 

How to get the application id of a powl dynamically

Former Member
0 Kudos

HI all,

I want to know if there is any way to get the application id of a powl dynamically.

I have developed many lists for which i have kept the same feeder class. For the first time it comes to the constructor of the feeder class i want to know what is the appliaction id of the list that triggered this..

I tried using CL_POWL_RUNTIME_SERVICES class, but no use..any inputs?

Regards,

Karthick.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

hi

use CL_POWL_MODEL->GET_APPLID()

best regards,

Rohit

Former Member
0 Kudos

thanks for ur response..

i have tried it..its nt working..

Former Member
0 Kudos

hello,

This is the way you can get the applid,

What you can do, In class CL_Powl_MODEL->intilalize also there is the way it is used to get the applid, Can you please check that also.

Former Member
0 Kudos

Hi,

I have tried all the below approaches..but not able to get it..

data: ls_query TYPE POWL_NAMEVALUE_TTY,

ls_data type POWL_EASY_META_STY. "Query

data:lo_obj type REF TO cl_powl_runtime_services,"CL_POWL_OBJECT_INFO."CL_POWL_EASY_SHAREDOBJ.

lo_obj1 type REF To CL_POWL_OBJECT_INFO,

lo_client type REF TO CL_WDR_CLIENT_APPLICATION,

lo_app type ref to IF_WDR_RR_APPLICATION.

create OBJECT lo_obj.

*lo_obj->GS_META = ls_data.

*create OBJECT lo_client.

CALL METHOD cl_powl_runtime_services=>get_powl_object_info_handle

receiving

ro_powl_object_info_handle = lo_obj1

EXCEPTIONS

no_wdr_component = 1

others = 2

.

IF sy-subrc <> 0.

  • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

  • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

*lo_client->IF_WDR_APPLICATION~APPLICATION_INFO = lo_app.

*create OBJECT i_class_instance1.

*

*CALL METHOD i_class_instance1->get_model

  • receiving

  • r_model = lr_model

  • .

CREATE OBJECT i_class_instance.

call METHOD i_class_instance->GET_APPLID

RECEIVING

RESULT = lv_appid.

i_class_instance->M_APPLID = lv_appid.

CALL METHOD i_class_instance->get_dynamic_details

IMPORTING

e_dyn_data = lt_dyn_data

e_dyn_cls = lt_dyn_cls

e_dyn_cls_instance = lt_dyn_inst

e_dyn_quick_crit = lt_quick_crit

e_dyn_sel_criteria = lt_dyn_sel_srit

.

data: l_value type string,

i_class_instance type REF TO CL_POWL_RUNTIME_SERVICES,"cl_powl_model,"IF_POWL_DYN_VAR,

i_class_instance1 type REF TO cl_powl_ui_helper,

e_dyn_params_def type POWL_PARAMS_DEF_TTY,

lt_dyn_data Type POWL_DYN_DATA_TTY,

lt_dyn_cls Type POWL_DYN_VAR_CLS_TTY,

lt_dyn_inst Type POWL_DYN_CLS_INSTANCE_TTY,

lt_quick_crit Type POWL_SELCRIT_TTY,

lt_dyn_sel_srit Type POWL_SELCRIT_TTY,

lv_appid type POWL_APPLID_TY,

lr_model type ref to CL_POWL_MODEL,

lt_add type POWL_NAMEVALUE_TTY,

ls_query type POWL_QUERY_STY,

lo_obj_handle TYPE ref to CL_POWL_OBJECT_INFO,

lt_messages type POWL_MSG_TTY.

CREATE OBJECT i_class_instance.

i_class_instance->MT_ADDITIONAL_PARAS = lt_add.

i_class_instance->MS_CURRENT_QUERY = ls_query.

i_class_interface->MO_OBJ_INFO_HANDLE = lo_obj_handle .

i_class_instance->MT_MESSAGES = lt_messages .

---

data: l_value type string,

i_class_instance type REF TO CL_POWL_model,"RUNTIME_SERvices,

lv_appid type POWL_APPLID_TY.

CREATE OBJECT i_class_instance.

call method i_class_instance->read_config_property(

EXPORTING i_property = 'POWL_APPLICATION_ID'

IMPORTING result = lv_appid ).

---

*CALL METHOD me->dyn_get_parameters

  • EXPORTING

  • i_class_instance = i_class_instance

  • IMPORTING

  • e_dyn_params_def =

.

*CALL METHOD i_class_instance->getparameters

  • EXPORTING

  • i_username = sy-uname

  • IMPORTING

  • e_params_def = e_dyn_params_def

  • .

*

  • CALL METHOD cl_wd_runtime_services=>get_url_parameter

  • EXPORTING

  • name = 'sap-accessibility'

  • RECEIVING

  • value = l_value.

Edited by: Karthick Kolisetty on Jan 25, 2010 12:12 PM