Access via null obj ref not possible error
Hi
I am using an assistance class and have specified it in the component...
i am getting the error Access via null obj ref not possible at following point in the code..
temp = wd_assist->IF_WD_COMPONENT_ASSISTANCE~GET_TEXT( key = '001' ).
i do not think we need to instantiate a assistance class ( or am i missing something ?/ )
Hi,
After reading all these posts and i have done a small test , it is working for me as the other posts already confirmed. I am not sure why it is not working for you the way you described and it is working for all others.
I hope that you are not executing this code from used component->view referring the WD_ASSIST where in the wd_assist reference is not passed.
moreover to make sure that the error is from this code you can code a if else construct.
if wd_assist is bound.
" get the text element.
endif.
If the above code is working then i suspect that the text element is not active .
Success.
Similar Messages
-
Webservice end up in Access via 'NULL' object reference not possible error
Hello everyone,
I have a particular issue when I run a webservice on webclient but when i run on sap R/3 it works fine.
The dump which it give when I test the web service is
Short text
Access via 'NULL' object reference not possible.
What happened?
Error in the ABAP Application Program
The current ABAP program "RPCTRSU0" had to be terminated because it has
come across a statement that unfortunately cannot be executed.
The code where it ends up in error is
2607 data: l_wb_interface type ref to fp_wb_interface.
2609 data: p_interface_data type ref to
fb_interface_data.
2610 data: l_interface TYPE REF TO
if_fp_interface.
2611 data: l_exceptions type ref to cx_root.
2613 data: l_parameters type ref to
if_fp_parameters,
2614 l_parameter_table type tfpiopar.
2615 data: l_fpintf_name type fpname.
2616 data: wa_dd03p type dd03p,
2617 DD40V_WA type dd40v.
2618 data: l_intf_imp_item type line of tfpiopar.
2620 l_fpintf_name = i51t8_adb_fpint.
2621 TRY.
2622 l_wb_interface = cl_fp_wb_interface=>load(
2623 i_name = l_fpintf_name
2624 i_mode =
if_fp_wb_object=>c_mode_read
2626 i_language = sy-langu
2627 ).
2628 CATCH cx_fp_api_usage into l_exceptions.
2629 * RAISE error.
2630 CATCH cx_fp_api_repository into l_exceptions.
2631 * RAISE error.
2632 CATCH cx_fp_api_internal into l_exceptions.
2633 * RAISE error.
2634 ENDTRY.
2635
>>>>> l_interface ?= l_wb_interface->get_object
2637 p_interface_data = l_interface->get_interface_data( ).
2638 l_parameters = p_interface_data->get_parameters( ).
Please let me know how to go about twith this error
Regards,
Rajx
-
Access via 'NULL' object reference not possible Error in WD application execution
Experts,
I am getting following error for web dynpro application intermittently, please find following error log:
What happened?
Error in the ABAP Application Program
The current ABAP program "CL_SALV_WD_C_TABLE_V_TABLE====CP" had to be
terminated because it has
come across a statement that unfortunately cannot be executed.
Error analysis
An exception occurred that is explained in detail below.
The exception, which is assigned to class 'CX_SY_REF_IS_INITIAL', was not
caught in
procedure "IF_SALV_WD_COMP_TABLE_DATA_MAP~MAP_TO_RESULT_CHANGES" "(METHOD)",
nor was it propagated by a RAISING clause.
Since the caller of the procedure could not have anticipated that the
exception would occur, the current program is terminated.
The reason for the exception is:
You attempted to use a 'NULL' object reference (points to 'nothing')
access a component.
An object reference must point to an object (an instance of a class)
before it can be used to access components.
Either the reference was never set or it was set to 'NULL' using the
CLEAR statement.
Information on where terminated
Termination occurred in the ABAP program "CL_SALV_WD_C_TABLE_V_TABLE====CP" -
in "IF_SALV_WD_COMP_TABLE_DATA_MAP~MAP_TO_RESULT_CHANGES".
The main program was "SAPMHTTP ".
In the source code you have the termination point in line 168
of the (Include) program "CL_SALV_WD_C_TABLE_V_TABLE====CM080".
The termination is caused because exception "CX_SY_REF_IS_INITIAL" occurred in
procedure "IF_SALV_WD_COMP_TABLE_DATA_MAP~MAP_TO_RESULT_CHANGES" "(METHOD)",
but it was neither handled locally nor declared
in the RAISING clause of its signature.
The procedure is in program "CL_SALV_WD_C_TABLE_V_TABLE====CP "; its source
code begins in line
1 of the (Include program "CL_SALV_WD_C_TABLE_V_TABLE====CM080 ".
Line SourceCde
138
139 "Set new value to result data
140 if ls_changelist-r_old_value is not bound.
141 "insert new table line
142 lr_component->r_result_data->if_salv_bs_r_data_table_edit~insert_table_line(
143 index = l_result_data_index ).
144 else.
145 "Modify existing table line
146 lr_component->r_result_data->if_salv_bs_r_data_table_edit~set_table_line(
147 index = l_result_data_index
148 data_line = <ls_table> ).
149 endif.
150 else.
151 "A single attribute value has to be updated
152
153 "Get context element from output data node
154 data lr_element type ref to if_wd_context_element.
155
156 "Retrieve the element to update from the data output node
157 if l_mass_edit_row_inserted = abap_true.
158 "The Element only exists virtually due to the mass edit mode.
159 lr_element = lr_node->get_element( l_mass_edit_virtual_index ).
160 l_mass_edit_row_inserted = abap_false.
161 else.
162 "The element already exists in the data output node.
163 lr_element = lr_node->get_element( ls_changelist-index ).
164 endif.
165
166 "Determine if the cell to be updated is set to null (Nullable)
167 data l_is_null type abap_bool.
>>>>> l_is_null = lr_element->is_attribute_null( ls_changelist-attribute ).
169
170 "Update result data with change
171 if <l_value> is assigned.
172 "update ResultData with cell value
173 lr_component->r_result_data->if_salv_bs_r_data_table_edit~set_table_cell(
174 index = l_result_data_index
175 attribute = ls_changelist-attribute
176 data_cell = <l_value>
177 is_null = l_is_null ).
178 else.
179 "Update result data without any updated cell value
180 lr_component->r_result_data->if_salv_bs_r_data_table_edit~set_table_cell(
181 index = l_result_data_index
182 attribute = ls_changelist-attribute
183 is_null = l_is_null ).
184 endif.
Please help us on what could be the reason behind this?
Thanks,
MadanHi Madan,
It seems that, there are user settings saved and the attribute in the layout settings is not available with current changes.
try to delete the user settings if any.
Please find my answer in the below link
Reset user settings in WDA
Hope this helps you.
Regards,
Rama -
Getting error on Portal : Access via 'NULL' object reference not possible
hi friends,
While executing a bapi,I am getting this error : Access via 'NULL' object reference not possible., error key: RFC_ERROR_SYSTEM_FAILURE
I am calling a bapi with only one required parameter from Portal as per the design of the bapi and the bapi itself is calling some other functions internally.
I a using ECC 5.00 i,e. EA-HR 5.00. On SDN it is suggested to Apply OSS Note 1018036. But it is applicable to EA-HR 6.00 and subsequent releases,I guess.
Need your suggestions and also need to know if the above Note can be applied to EA-HR 5.00.
P.S: Points would be assigned, thanks is advance.
Regards,
Sudeep DasHi,
ESS Personal information scenarios
Reason and Prerequisites
In case record is not modified successfully it should discard the
trial.Due to program error this was not happening correctly
Solution
Code changes were done in ESS adapter to handle this scenario
Hope this helps
Regards
Krishna -
RFC_ERROR_SYSTEM_FAILURE - - Access via NULL object reference not possible
Hi,
RFC was working fine , suddenly starting showing error below ( not sure if i changed anything ) -
Rest of the RFC's in the same app are working fine.
The error throwed is -
com.sap.tc.webdynpro.modelimpl.dynamicrfc.WDDynamicRFCExecuteException: Access via NULL object reference not possible., error key: RFC_ERROR_SYSTEM_FAILURE
Full error details -
com.sap.tc.webdynpro.modelimpl.dynamicrfc.WDDynamicRFCExecuteException: Access via NULL object reference not possible., error key: RFC_ERROR_SYSTEM_FAILURE
at com.sap.tc.webdynpro.modelimpl.dynamicrfc.DynamicRFCModelClassExecutable.execute(DynamicRFCModelClassExecutable.java:101)
at com.sap.xss.per.fc.persinfo.FcPersInfo.onCleanup(FcPersInfo.java:561)
at com.sap.xss.per.fc.persinfo.wdp.InternalFcPersInfo.onCleanup(InternalFcPersInfo.java:798)
at com.sap.xss.per.fc.persinfo.FcPersInfoInterface.onCleanup(FcPersInfoInterface.java:246)
at com.sap.xss.per.fc.persinfo.wdp.InternalFcPersInfoInterface.onCleanup(InternalFcPersInfoInterface.java:299)
at com.sap.xss.per.fc.persinfo.wdp.InternalFcPersInfoInterface$External.onCleanup(InternalFcPersInfoInterface.java:459)
at com.sap.pcuigp.xssfpm.wd.FPMComponent.cleanUp(FPMComponent.java:644)
at com.sap.pcuigp.xssfpm.wd.FPMComponent.access$1000(FPMComponent.java:78)
at com.sap.pcuigp.xssfpm.wd.FPMComponent$FPM.exitCalled(FPMComponent.java:963)
at com.sap.pcuigp.xssfpm.wd.FPMComponent$FPMProxy.exitCalled(FPMComponent.java:1134)
at com.sap.pcuigp.xssfpm.wd.BackendConnections.wdDoExit(BackendConnections.java:124)
at com.sap.pcuigp.xssfpm.wd.wdp.InternalBackendConnections.wdDoExit(InternalBackendConnections.java:228)
at com.sap.tc.webdynpro.progmodel.generation.DelegatingCustomController.doExit(DelegatingCustomController.java:77)
at com.sap.tc.webdynpro.progmodel.controller.Controller.exitController(Controller.java:180)
at com.sap.tc.webdynpro.progmodel.controller.Controller.exit(Controller.java:154)
at com.sap.tc.webdynpro.progmodel.controller.Component.exitController(Component.java:251)
at com.sap.tc.webdynpro.progmodel.controller.Controller.exit(Controller.java:154)
at com.sap.tc.webdynpro.clientserver.cal.ClientComponent.exit(ClientComponent.java:219)
at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.exit(ClientApplication.java:474)
at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.destroy(ClientApplication.java:527)
at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.destroy(ApplicationSession.java:398)
at com.sap.tc.webdynpro.clientserver.session.ClientWindow.destroyApplicationSession(ClientWindow.java:235)
at com.sap.tc.webdynpro.clientserver.session.ClientSession.doDestroyApplication(ClientSession.java:1003)
at com.sap.tc.webdynpro.clientserver.session.ClientSession.doSessionManagementPostProcessing(ClientSession.java:789)
at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:264)
at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:149)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doContent(DispatcherServlet.java:62)
at com.sap.tc.webdynpro.serverimpl.defaultimpl.DispatcherServlet.doGet(DispatcherServlet.java:46)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:401)
at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:266)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:386)
at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:364)
at com.sap.engine.services.httpserver.server.RequestAnalizer.invokeWebContainer(RequestAnalizer.java:1039)
at com.sap.engine.services.httpserver.server.RequestAnalizer.handle(RequestAnalizer.java:265)
at com.sap.engine.services.httpserver.server.Client.handle(Client.java:95)
at com.sap.engine.services.httpserver.server.Processor.request(Processor.java:175)
at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)
at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)
at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
at java.security.AccessController.doPrivileged(AccessController.java:219)
at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102)
at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172)
Caused by: com.sap.aii.proxy.framework.core.BaseProxyException: Access via 'NULL' object reference not possible., error key: RFC_ERROR_SYSTEM_FAILURE
at com.sap.aii.proxy.framework.core.AbstractProxy.send$(AbstractProxy.java:150)
at com.sap.xss.per.model.mac.HRXSS_PER_MAC.hrxss_Per_Cleanup(HRXSS_PER_MAC.java:331)
at com.sap.xss.per.model.mac.Hrxss_Per_Cleanup_Input.doExecute(Hrxss_Per_Cleanup_Input.java:137)
at com.sap.tc.webdynpro.modelimpl.dynamicrfc.DynamicRFCModelClassExecutable.execute(DynamicRFCModelClassExecutable.java:92)
... 43 more
Thanks,
Regards,
AnkitHello Vaish & Ankit,
Can you check what is the dump occurred in transaction ST22?
I hope you guys are working with HR data. So, i think some object is not passed(internally) correctly in RFC.
Please debug the RFC by keeping the breakpoint from webdynpro application, then you will come to know what is not passed when we execute the RFC from R/3.
Regards
Nizamudeen SM -
Web-UI error message "Access via 'NULL' object reference not possible"
I need some help, I'm not a Basis person but I need to get this connection problem resolve.
This problem is in our DEV ICWeb system. After logging in to Web-UI, I got a error message "Access via 'NULL' object reference not possible". We have 3 clients (100, 220, & 310) in DEV and all 3 clients are giving me the same error message.
From the help.sap.com, I found this topic http://help.sap.com/saphelp_nwes70/helpdata/en/84/43f0d786304e19a652a8f80909a8ec/content.htm
but in the document it asked to go to SM59 to check the ESH_APPL_WS_TEMPLATEENGINE destination. But we don't have that destination setup in all our systems.
Here is the complete error message:
Error when processing your request
What has happened?
The URL http://crm-dev.staff.copa:8000/sap/bc/bsp/sap/crm_ui_frame/BSPWDApplication.do was not called due to an error.
Note
■The following error text was processed in the system CD1 : Access via 'NULL' object reference not possible.
■The error occurred on the application server CRM-DEV_CD1_00 and in the work process 0 .
■The termination type was: RABAX_STATE
■The ABAP call stack was:
Method: GET_DATA_LOSS_HANDLER of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
Method: GET_DATA_LOSS_HANDLER of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
Method: EH_TRIGGER_NAVIGATION of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
Method: SET_WORKAREA_CONTENT of program CL_CRM_UI_CORE_APPL_CONTROLLERCP
Method: PROCESS_NAV_QUEUE of program CL_BSP_WD_VIEW_MANAGER========CP
Method: DO_INIT of program CL_CRM_UI_FRAME_APP_CONTROLLERCP
Method: DO_INIT of program CL_BSP_CTRL_ADAPTER===========CP
Method: GET_PAGE_CONTEXT_CURRENT of program CL_BSP_CONTEXT================CP
Method: ON_REQUEST_ENTER of program CL_BSP_RUNTIME================CP
Method: ON_REQUEST of program CL_BSP_RUNTIME================CP
What can I do?
■If the termination type was RABAX_STATE, then you can find more information on the cause of the termination in the system CD1 in transaction ST22.
■If the termination type was ABORT_MESSAGE_STATE, then you can find more information on the cause of the termination on the application server CRM-DEV_CD1_00 in transaction SM21.Hi Michael,
Refer to the link below and check the procedure.
http://help.sap.com/saphelp_nwes70/helpdata/en/84/43f0d786304e19a652a8f80909a8ec/content.htm
Regards,
Arjun -
Runtime error in WebDynpro - Access via 'NULL' object reference not possibl
Hi,
Structure of the CONTEXT in the VIEW::
WDSCREEN1
--> IMPORTING
--> S_KUNNR <- its a select option
--> EXPORTING
--> T_REPORT <- Which is table to hold the output data (with 4 fields)
In the context area i have root node (WDSCREEN1) and Sub nodes are IMPORTING and EXPORTING and child nodes as shown above. When i am referring them everything is fine except T_REPORT.
* Declaration
DATA: node TYPE REF TO if_wd_context_node,
node_exporting TYPE REF TO if_wd_context_node,
node_importing TYPE REF TO if_wd_context_node,
node_report TYPE REF TO if_wd_context_node,
node = wd_context->get_child_node( wd_this->wdctx_wdscreeb1 ).
node_exporting = node->get_child_node( wd_this->wdctx_exporting ).
node_importing = node->get_child_node( wd_this->wdctx_importing ).
* Bind the data to the context
node_report = node_exporting->get_child_node( name = 'T_REPORT` ).
node_report->bind_elements( lt_report ).
Its giving run time error 'Access via 'NULL' object reference not possible. ' when it comes to ' node_report->bind_elements( lt_report ).' I checked the content while debugging and found that it was initial. Not sure why Node_report is initial. all others have data.
node ->
node_exporting ->
node_importing ->
node_report ->http://wiki.sdn.sap.com/wiki/display/EP/PointersforTroubleshootingPortalRuntime+Errors
Hope this helps.
-Veer -
Hi all ,
Im getting the below error , actually recently i created my own custom table zstudent, later i wrote select query to fetch data from the same and dump at internal table and then bind this to the table node.
But im getting below error, even i removed the select query still same error is occuring.
Error when processing your request
What has happened?
The URL http://********00.*****b.com:8000/sap/bc/webdynpro/sap/zdemo_student/ was not called due to an error.
Note
The following error text was processed in the system IDS : Access via 'NULL' object reference not possible.
The error occurred on the application server axsids00_IDS_00 and in the work process 0 .
The termination type was: RABAX_STATE
The ABAP call stack was:
Method: WDDOINIT of program /1BCWDY/YUSM2Q74A826Y0JY1I4V==CP
Method: IF_WDR_COMPONENT_DELEGATE~WD_DO_INIT of program /1BCWDY/YUSM2Q74A826Y0JY1I4V==CP
Method: DO_INIT of program CL_WDR_DELEGATING_COMPONENT===CP
Method: INIT_CONTROLLER of program CL_WDR_CONTROLLER=============CP
Method: INIT_CONTROLLER of program CL_WDR_COMPONENT==============CP
Method: INIT of program CL_WDR_CONTROLLER=============CP
Method: INIT of program CL_WDR_CLIENT_COMPONENT=======CP
Method: INIT of program CL_WDR_CLIENT_APPLICATION=====CP
Method: IF_WDR_RUNTIME~CREATE of program CL_WDR_MAIN_TASK==============CP
Method: HANDLE_REQUEST of program CL_WDR_CLIENT_ABSTRACT_HTTP===CPThanks Rama,
Acutally i accidentally commented the lo_nd_student = wd_context ....etc
this line was commented .
i have one small requirement to fetch data from local customised table and fill the same to internal table and bind that to table node.
my table node is student having attributes as name , city and number , all are of type strings.
now i created one custom table zstudent having ID - char of length 10,
name of type string
city of type string
num of type string
i have inserted records
but when i use select query to fill data from this zstudent to my internal table of type lt_student type wd_this->elements_student ,
im getting same above error. -
Error when save project Access via 'NULL' object reference not possible PLM
Dear All,
we are using cProject (PLM)4.0
When i create project & try to save ,system gives me error 'Access via 'NULL' object reference not possible'
Steps
1.Create project & element
2.save
showing below error
Note
The following error text was processed in the system PLD : Access via 'NULL' object reference not possible.
The error occurred on the application server Ndimdev_PLD_20 and in the work process 0 .
The termination type was: RABAX_STATE
The ABAP call stack was:
Error code: ICF-IE-http -c: 300 -u: PLMUSER1 -l: E -s: PLD -i: Ndimdev_PLD_20 -w: 0 -d: 20090702 -t: 164926 -v: RABAX_STATE -e: OBJECTS_OBJREF_NOT_ASSIGNED
Please do needful
Regards
RavindraHi,
Put a break point and check whther ur node and
element instantiation is properly done.
Thanks,
Divya.S -
Hi Guru's,
i am new for WebDynpro programming.I am trying to use select-options tutorial.
System showing select options and table binding on screen when i test the application.
I have using search button to get the value which user will i/p.for that onaction method created, i have writen the code to get the values which user will input.
Method given below is of componentcontroler
method wddoinit .
data: lt_range_table type ref to data,
rt_range_table type ref to data,
read_only type abap_bool,
lt_range_table1 type ref to data.
data: lr_componentcontroller type ref to ig_componentcontroller,
l_ref_cmp_usage type ref to if_wd_component_usage.
create the used component
l_ref_cmp_usage = wd_this->wd_cpuse_select_options( ).
if l_ref_cmp_usage->has_active_component( ) is initial.
l_ref_cmp_usage->create_component( ).
endif.
wd_this->m_wd_select_options = wd_this->wd_cpifc_select_options( ).
wd_this->m_handler = wd_this->m_wd_select_options->init_selection_screen( ).
wd_this->m_handler->set_global_options(
i_display_btn_cancel = abap_false
i_display_btn_check = abap_false
i_display_btn_reset = abap_false
i_display_btn_execute = abap_false ).
lt_range_table = wd_this->m_handler->create_range_table( i_typename = 'S_CARR_ID' ).
wd_this->m_handler->add_selection_field( i_id = 'CARRID'
it_result = lt_range_table i_read_only = read_only ).
call method wd_this->m_handler->add_horizontal_divider
exporting
i_id = 'LINE'.
endmethod.
Method given below is of VIEW.
method ONACTIONSEARCH .
DATA: NODE_FLIGHTS TYPE REF TO IF_WD_CONTEXT_NODE.
DATA: RT_CARRID TYPE REF TO DATA.
DATA: ISFLIGHT TYPE TABLE OF SFLIGHT.
DATA: WSFLIGHT TYPE SFLIGHT.
FIELD-SYMBOLS: <FS_CARRID> TYPE TABLE.
Retrieve the data from the select option
RT_CARRID = WD_THIS->M_HANDLER->GET_RANGE_TABLE_OF_SEL_FIELD( I_ID = 'S_CARR_ID' ).
Assign it to a field symbol
ASSIGN RT_CARRID->* TO <FS_CARRID>.
CLEAR ISFLIGHT. REFRESH ISFLIGHT.
SELECT * INTO CORRESPONDING FIELDS OF TABLE ISFLIGHT FROM SFLIGHT
WHERE CARRID IN <FS_CARRID>.
NODE_FLIGHTS = WD_CONTEXT->GET_CHILD_NODE( NAME = `FLIGHTS` ).
NODE_FLIGHTS->BIND_ELEMENTS( ISFLIGHT ).
endmethod.
while executing appln. error is trigger on line given below
RT_CARRID = WD_THIS->M_HANDLER->GET_RANGE_TABLE_OF_SEL_FIELD( I_ID = 'S_CARR_ID' ).
Err: The following error text was processed in the system BCD : Access via 'NULL' object reference not possible.
please help me out on this issue.
Thanks and Regards
Vinayak Sapkalhi ,
The attribute M_HANDLER is an attirbute of component controller (as told by your post) and so you cannot access it as you have done it.
You will have to access it as .
WD_COMP_CONTROLLER->M_HANDLER->GET_RANGE_TABLE_OF_SEL_FIELD(I_ID = 'S_CARR_ID' ).
Try doing it.
Or else , if you have created a similar attribute in your view itself , then it is "INITIAL" and hence you are getting the dump.
You will have to assign the view attribute "M_HANDLER" with the value of your component controller attribute "M_HANDLER" ,because all the initializations are done in WDDOINIT of comp controller and on component controller atribute "M_HANDLER".
Thanks,
aditya. -
IC WEBCLIENT: Access via 'NULL' object reference not possible
Hi,
Iam working in ABAP, and learning CRM ABAP on CRM5.0 IDES Demo system I was trying to create a new WebIC by copying one view from CRM_IC to ZCRM_IC bsp application. Following are the steps I following according to Cook book documentation.
1. I copied BuPaDisplayCustomer view and controller from CRM_IC to ZCRM_IC from
BSP_WD_WORKBENCH by selecting CRM_IC and runtime profile = 'DEFAULT'.
2. Created a runtime profile from SPRO->CRM->IC Webclient->Customer specific modifications->Define
runtime profile.
3. Copied the 'DEFAULT' runtime profile to my new profile 'Z_COOKBOOK'. Assign 'ZCRM_IC' by
clicking on 'Controller and substitues'.
BSP Replaced Controller BSP ReplacmentController
CRM_IC BuPaMoreContactView Z_CRM_IC BuPaMoreContactView
4. Define IC Webclient profile:
SPRO->CRM->IC Webclient->Define IC Webclient profile->Copy the DEFAULT profile and assign it to
'Z_COOKBOOK',
5. Assigned the Webclient profile to the user from t-code 'PPOMW'. Selected 'USER' from the
existing 'Position' and Goto->Detail object->Enhanced obj descrption.Selected IC webclient from the
list and created Infotype assigned Webclient profile 'Z_COOKBOOK'.
6. Execute the ZCRM_IC from SE80 by rightclick and Test. Here is my problem,Iam receiving the
following error in the webpage.
The following error text was processed in the system CR7 :
Access via 'NULL' object reference not possible.
The error occurred on the application server CR7_01 and in the work process 0 .
The termination type was: RABAX_STATE
The ABAP call stack was:
Method: SET_MODELS of program CL_CRM_IC_BUPADISPCUSTOME=====CP
Method: SET_MODELS of program CL_CRM_IC_BUPADISPCUSTOME=====CP
Method: SET_MODELS of program CL_CRM_IC_BUPADISPCUSTOME_IMPLCP
Method: DO_REQUEST of program CL_BSP_WD_VIEW_CONTROLLER=====CP
Method: DO_REQUEST of program CL_BSP_CTRL_ADAPTER===========CP
Method: ON_REQUEST of program CL_BSP_RUNTIME================CP
Method: IF_HTTP_EXTENSION~HANDLE_REQUEST of program CL_HTTP_EXT_BSP===============CP
Method: EXECUTE_REQUEST_FROM_MEMORY of program CL_HTTP_SERVER================CP
Function: HTTP_DISPATCH_REQUEST of program SAPLHTTP_RUNTIME
Module: %_HTTP_START of program SAPMHTTP
I check the CRM services and all are active, using IE8 web browser. I just copied the view and controller
from CRM_IC into Custom BSP application i.e., ZCRM_IC.
Above error is occuring even If i run the standard CRM_IC BSP application and select one simple view.
from SE80.
Not sure whether any additional configuration or any special roles to be assigned to the Webclient profile.
Thanks,
Venn.hello swapna,
we are facing the same error while accessing the leave request link, all jco are testing fine, i checked backend connection and its fine, please tel me how did u resolved that issue,
Thanks in advance.....
ajay -
Access via NULL reference object not possible
Hi friends,
I have created an wda application which uses the table popin to display data.
So that i have created a view with two of the fields as link to action UI element.
In the Events/Actions of the link to action element i implemented the following logic.
data wd_table_cell_editor type ref to cl_Wd_view_element.
data wd_table_column type ref to cl_wd_table_column.
data wd_popin type ref to cl_wd_table_popin.
data id type string.
<b> wd_table_cell_editor ?= wd_this->m_view->get_element( id ).</b>
wd_table_column ?= wd_table_cell_editor->get__parent( ).
wd_popin = wd_table_column->get_popin( ).
context_element->set_attribute( name = 'SELECTED_POPIN' value =
wd_popin->id ).
So when i click on the link to action in the table column of the field am getting the following error
<b>Access via NULL reference object not possible.</b>
While debugging i have noticed that this error was coming at the below step of the code.
<b>wd_table_cell_editor ?= wd_this->m_view->get_element( id )</b>
in the m_view->get_element( id ) does not contan any value , its showing as table , as null value cannnot be assigned may be its throwing the above error.
But i didnt understand why the view is not getting UI element id ....
Can one please suggest me where might be the wrong....
Regards
Sireesha.Hi nithya,
Could you please calrify the doubts for the following q's.
1. As u said in the above post, i have changed the code to the below.
data: lr_table type ref to cl_wd_table,
lr_table_col type ref to cl_wd_table_column.
lr_table ?= wd_this->m_view->get_element( 'TABLE' ).
lr_table_col = lr_table->get_column( ID = 'TABLE_CONNECTID' ).
<b>wd_popin = lr_table_col->get_popin( ).</b>
(At the above step which is in bold , eventhough there is value in lr_table_col->get_popin , its not assigning a value to the wd_popin, throwing same error NULL etc.,)
context_element->set_attribute( name = 'SELECTED_POPIN' value =
wd_popin->id ).
2. Before changing the code suggested by u, the follwoing was the code from standard example.Its working fine in the application wdr_test_table.I have debugged the code.The value is getting assigned into wd_table_cell_editor.
The same thing i have done but its failing to assign the value. thats y its throwing null reference error. Here i have a confusion how its assigning a value and y not in the z application.am giving the code below which is in standard and my application.Please clarify these.
data wd_table_cell_editor type ref to cl_Wd_view_element.
data wd_table_column type ref to cl_wd_table_column.
data wd_popin type ref to cl_wd_table_popin.
<b>wd_table_cell_editor ?= wd_this->m_view->get_element( id ).</b>
( Note : wd_this->m_view->get_element contains value but not assigning it to the wd_table_cell_editor and same code in the standard behaving correctly like assigning the view value to the cell editor. Y this behavior, please advice me)
wd_table_column ?= wd_table_cell_editor->get__parent( ).
wd_popin = wd_table_column->get_popin( ).
context_element->set_attribute( name = 'SELECTED_POPIN' value = wd_popin->id )
Regards
Sireesha. -
WebDynpro Abap MSS: Access via "NULL" object reference not possible
hi,
My customer send me the following link to Appraisal Documents (Manager) MSS
http://server.sap.portal:1810/sap/bc/webdynpro/sap/HAP_START_PAGE_POWL_UI_MSS/
http://a.imageshack.us/img685/5959/mss3.jpg (logon in Costumer SAP System)
http://a.imageshack.us/img225/4008/mss4.jpg (Appraisal Documents (Manager) MSS run succesful)
Link that also run by the SICF in my customer is correct.
But when I run in my SAP System see the following error
http://a.imageshack.us/img715/5355/mss1j.jpg (SCIF in my SAP System)
http://a.imageshack.us/img44/5346/mss2.jpg (SCIF - test service)
http://a.imageshack.us/img840/1677/mss2b.jpg (Error, without window logon)
<b> Access via "NULL" object reference not possible</b>
Other question is: In what part of MSS is this option? because the ESS is in Career and Jobs / Appraisals Documents
http://a.imageshack.us/img683/9900/careerjob3.jpg (Employee Self Service / Career and Jobs / Appraisals Documents)
thanks for your posts and answer
IvanHello
The most important information is (again) missing: which object reference is initial ("NULL")?
The ABAP dump will tell you.
Below I show an example how this can happen (and be avoided):
LOOP AT lt_accountings INTO ls_accounting.
lo_po_account ?= ls_accounting-accounting.
ENDLOOP.
" QUESTION: Are you sure that lo_po_account hold an instance ???
" If LO_PO_ACCOUNT is empty the following statement will give you the dump.
ls_mepoaccounting = lo_po_account->get_data( ).
" And that is how to avoid this (at least the dump. Whether your logic is still ok is another matter...)
CHECK ( lo_po_account IS BOUND ).
ls_mepoaccounting = lo_po_account->get_data( ).
Regards
Uwe -
BSP - 500 Internal Server Error Access via 'NULL' object reference not possible.
Hello Colleagues, I'm new to BSP maybe someone could help me.
I’m taking data from a DB table through select an put them into htmlb tables.
The layout looks like:
<htmlb:tableViewColumn columnName="PK_Terms"
<%--wrapping="true"--%>
width="50"
horizontalAlignment = "center"
verticalAlignment = "middle"
fixedColumn="true">
</htmlb:tableViewColumn>
After I select the vendor (first table), another table appears with additional Info (see screenshot). I've set the the visible row count to 10 and the data appears without errors, but when I click the next page button or type page number to see the next 10 rows, following error message appears:
The ABAP call hierarchy was:
Method: _ONINPUTPROCESSING of program CL_O2DH4AGZFD1H3VPXDQ9541G8559CP
Method: %_ONINPUTPROCESSING of program CL_O2DH4AGZFD1H3VPXDQ9541G8559CP
Method: DO_REQUEST of program CL_BSP_PAGE===================CP
Method: ON_REQUEST of program CL_BSP_RUNTIME================CP
Method: IF_HTTP_EXTENSION~HANDLE_REQUEST of program CL_HTTP_EXT_BSP===============CP
Method: EXECUTE_REQUEST_FROM_MEMORY of program CL_HTTP_SERVER================CP
Function: HTTP_DISPATCH_REQUEST of program SAPLHTTP_RUNTIME
Module: %_HTTP_START of program SAPMHTTP
My select statement:
if tv_data->row_key is not initial.
select ekko~lifnr ekko~ekorg as po ekpo~netwr as netwr ekko~bukrs as cc
ekpo~ebeln from ekpo join ekko on ekpo~ebeln eq ekko~ebeln
into corresponding fields of table lt_ek1
where lifnr eq tv_data->row_key.
Whats wrong ?Hi Pramod,
we have already checked and maintain also.
but no use.
and this user moved to QUA and maintain Personnel number also it is working well in QUA.
but it is not working in PRD. it is having all authorizations also.
once we deleted user in PRD and then created in PRD assign all roles but no use.
we got same error in particular USER only.
and clear the cache in portal side and browser side also there is no use.
and PMS documentation update it.but no use.
what is missing authorization to particular user and how to solve this issue please suggest us.
regards
nagendra -
Access via 'NULL' object reference not possible.
hi all,
i am getting the following error in my application(getting data from 2 data base table and kept in internal table and binding that 2 internal table to two context)
in st22 i have this.
Error analysis
An exception occurred that is explained in detail below.
The exception, which is assigned to class 'CX_SY_REF_IS_INITIAL', was not
caught in
procedure "PARSE_XML_DATA" "(METHOD)", nor was it propagated by a RAISING
clause.
Since the caller of the procedure could not have anticipated that the
exception would occur, the current program is terminated.
The reason for the exception is:
You attempted to use a 'NULL' object reference (points to 'nothing')
access a component.
An object reference must point to an object (an instance of a class)
before it can be used to access components.
Either the reference was never set or it was set to 'NULL' using the
CLEAR statement.
gettong error at line 52.
24 data: parseerror type ref to if_ixml_parse_error,
25 str type string, "#EC NEEDED
26 i type i, "#EC NEEDED
27 count type i,
28 index type i.
29 count = parser->num_errors( ).
30 * write: count, ' parse errors have occured:'.
31 index = 0.
32 while index < count.
33 parseerror = parser->get_error( index = index ).
34 i = parseerror->get_line( ).
35 * write: 'line: ', i.
36 i = parseerror->get_column( ).
37 * write: 'column: ', i.
38 str = parseerror->get_reason( ).
39 * write: str.
40 index = index + 1.
41 endwhile.
42 endif.
43 endif.
44
45 data l_ref_ixml_elem type ref to if_ixml_element.
46 l_ref_ixml_elem = l_ref_doc->get_root_element( ).
47
48 data l_ref_node_list type ref to if_ixml_node_list.
49 data l_ref_child type ref to if_ixml_node.
50 data nodes_index type i value 0.
51 data l_count type i.
>>>> l_ref_node_list = l_ref_ixml_elem->get_children( ).
53 while nodes_index < l_ref_node_list->get_length( ).
54 l_ref_child = l_ref_node_list->get_item( nodes_index ).
55 nodes_index = nodes_index + 1.
56 l_count = l_ref_child->num_children( ).
57 if l_count > 0.
58 me->parse_xml_subnode( subnode = l_ref_child index = 0
59 with_initial_attributes = with_initial_attributes ).
60 elseif with_initial_attributes = abap_true.
61 me->parse_xml_subnode( subnode = l_ref_child index = 0
62 with_initial_attributes = with_initial_attributes ).
pls help me
regards,
vinoth.hi thomas,
thanks for ur reply.
this is my scenario:
my context:
>contract(root node with cardinality 1:1)
>mandt_ekko( 1:1)
ebeln
>disp_ekko(o:n)
bstyp
lifnr
>disp_ekpo(o:n)
ebelp
txz01
based on ebeln fetched at run time. i have to display ekko and ekpo table details in form.i have fetched values based on that ebeln and put it in 2 internal table from ekko and ekpo table and binded that to context.but getting error.
my code:
method ONACTIONSUBMIT .
DATA lo_nd_contract TYPE REF TO if_wd_context_node.
DATA lo_nd_mandt_ekko TYPE REF TO if_wd_context_node.
DATA lo_el_mandt_ekko TYPE REF TO if_wd_context_element.
DATA ls_mandt_ekko TYPE wd_this->element_mandt_ekko.
* navigate from <CONTEXT> to <CONTRACT> via lead selection
lo_nd_contract = wd_context->get_child_node( name = wd_this->wdctx_contract ).
* navigate from <CONTRACT> to <MANDT_EKKO> via lead selection
lo_nd_mandt_ekko = lo_nd_contract->get_child_node( name = wd_this->wdctx_mandt_ekko ).
* get element via lead selection
lo_el_mandt_ekko = lo_nd_mandt_ekko->get_element( ).
* get all declared attributes
lo_el_mandt_ekko->get_static_attributes(
IMPORTING
static_attributes = ls_mandt_ekko ).
DATA lo_nd_disp_ekko TYPE REF TO if_wd_context_node.
DATA lo_el_disp_ekko TYPE REF TO if_wd_context_element.
DATA ls_disp_ekko TYPE wd_this->element_disp_ekko.
* navigate from <CONTEXT> to <CONTRACT> via lead selection
lo_nd_contract = wd_context->get_child_node( name = wd_this->wdctx_contract ).
* navigate from <CONTRACT> to <DISP_EKKO> via lead selection
lo_nd_disp_ekko = lo_nd_contract->get_child_node( name = wd_this->wdctx_disp_ekko ).
* @TODO handle not set lead selection
IF lo_nd_disp_ekko IS INITIAL.
ENDIF.
* get element via lead selection
lo_el_disp_ekko = lo_nd_disp_ekko->get_element( ).
* @TODO handle not set lead selection
IF lo_el_disp_ekko IS INITIAL.
lo_el_disp_ekko = lo_nd_disp_ekko->create_element( ).
ENDIF.
data: IT_EKKO TYPE standard table of EKKO,
lo_nd_snode_1 TYPE REF TO if_wd_context_node.
select * from EKKO into table it_EKKO WHERE EBELN = ls_mandt_ekko-EBELN.
if sy-subrc eq 0.
lo_nd_snode_1 = wd_context->path_get_node( 'CONTRACT.DISP_EKKO' ).
lo_nd_snode_1->bind_table( it_EKKO ).
endif.
DATA lo_nd_disp_ekpo TYPE REF TO if_wd_context_node.
DATA lo_el_disp_ekpo TYPE REF TO if_wd_context_element.
DATA ls_disp_ekpo TYPE wd_this->element_disp_ekpo.
* navigate from <CONTEXT> to <CONTRACT> via lead selection
lo_nd_contract = wd_context->get_child_node( name = wd_this->wdctx_contract ).
* navigate from <CONTRACT> to <DISP_EKPO> via lead selection
lo_nd_disp_ekpo = lo_nd_contract->get_child_node( name = wd_this->wdctx_disp_ekpo ).
* @TODO handle not set lead selection
IF lo_nd_disp_ekpo IS INITIAL.
ENDIF.
* get element via lead selection
lo_el_disp_ekpo = lo_nd_disp_ekpo->get_element( ).
* @TODO handle not set lead selection
IF lo_el_disp_ekpo IS INITIAL.
lo_el_disp_ekpo = lo_nd_disp_ekpo->create_element( ).
ENDIF.
data: lo_nd_snode_2 TYPE REF TO if_wd_context_node,
IT_EKPO TYPE standard table of EKPO.
select * from EKPO into table it_EKPO WHERE EBELN = ls_mandt_ekko-EBELN.
if sy-subrc eq 0.
lo_nd_snode_2 = wd_context->path_get_node( 'CONTRACT.DISP_EKPO' ).
lo_nd_snode_2->bind_table( it_EKPO ).
ENDIF.
endmethod.
when i execute got that error.any help highly appreciated.
regards,
vinoth.
Edited by: Thomas Jung on Aug 10, 2009 8:10 AM
Maybe you are looking for
-
Hi, I just downloaded Windows 7 onto my 17'' Macbook pro via boot camp, however when in Windows it doesn't pick up any wireless networks to even attempt to connect too. However, when in Mac it automatically connects to the wireless connection in my h
-
Hi, I have one basic question regarding CIF. We are assigning queue type to scm system at two places. 1. In SCM system with tcode-/SAPAPO/C2(Assign logical system to buisness system group) 2. In Ecc system with tcode-CFC1(Define target system operati
-
Hi, how to Create Webservices for XI message interfaces? Please help me out. Thanks.
-
ColdFusion startup script?
I'm running CF8 Server under Windows. I have an application, MyApplication, in which, for a variety of reasons, I refresh some application-scope arrays on a schedule. To simplify just a bit, there is a ColdFusion script that runs each hour, and in th
-
my iPhone contact are missing, only call log is available, and the contact can seen in the whatsapp etc