Skip to Content
avatar image
Former Member

Hello experts : Error Access via 'NULL' object reference not possible.

Hi ,

I am in the process of developing my first webynpro adobe interactive form application ,

I have 2 fields in the from Deptno and Dept name .. My purpose is to catche the event click in the form and save it to a Database

I am using a ZCLI form , My context struture is Node Adobe under which zdept1 node under which 2 attributes deptname and depno are there .

My error is : The form gets loaded and when I submit the click button I get an error

Error Access via 'NULL' object reference not possible.

Cardinality for Node : Adobe 1:1

Cardinality for node zdept is 1: 1

Data source propert y is mapped to node zdept

and PDFsource is also mapped to PDFSource type string

Can you gusy let me know the issue for this error?



Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Nov 04, 2009 at 04:21 PM

    This kind of things (WD, especially when youre a beginner) are very difficult to describe enough to get help. I can recommend reading and following some short WD Abap Adobe form tutorial. You need to do like ten clicks to create the most simple WD Abap Adobe app so it will not be a problem for you to follow the tutorial.

    Also when facing a problem in development you can point out the tutorial source so the SDN gurus can help you using the same source.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 04, 2009 at 05:00 PM

    Hi Abhilash,

    You will get that error if you try to access the node or attribute without any reference.

    Use the following code in the action to access the data.

    data: lo_nd_adobe type ref to if_wd_context_node,

    lo_nd_zdept type ref to if_wd_context_node,

    ls_zdept type wd_this->element_zdept.

    lo_nd_adobe = wd_context->get_child_node( name = wd_this->wdctx_adobe ).

    lo_nd_zdept = lo_nd_adobe->get_child_node( name = wd_this->wdctx_zdept ).

    to get the values deptname & deptno, use the belwo code:

    lo_nd_zdept ->get_static_attributes( IMPORTING static_attributes = ls_zdept ).

    From ls_zdept you can access deptname & deptno into required fields or directly the field values like ls_zdept-deptname & ls_zdept -deptno.

    Hope this helps.



    Add comment
    10|10000 characters needed characters exceeded