Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

LDB_PROCESS for PNP

Former Member
0 Likes
932

Hi all,

I am trying to use LDB_PROCESS function module for logical database PNP but am not sucessful in it.

I am pasting my code below:

Moderator message - Please respect the 2,500 character maximum when posting. Post only the relevant portions of code

The problem i am facing is that the FM is processed perfectly but callback routine is not called.

Kindly help...

Seema Peswani

ABAP HR

Edited by: Rob Burbank on Nov 13, 2009 9:43 AM

Hi all,

I am trying to use LDB_PROCESS function module for logical database PNP but am not sucessful in it.

I am pasting my code below:

Moderator message - Please respect the 2,500 character maximum when posting. Post only the relevant portions of code

The problem i am facing is that the FM is processed perfectly but callback routine is not called.

Kindly help...

Seema Peswani

ABAP HR

Edited by: Rob Burbank on Nov 13, 2009 9:43 AM

4 REPLIES 4
Read only

Former Member
0 Likes
662

Hi Seema,

I didnt find any problem with this code. I got a value populated in the routine CALLBACK.

Regards

Abhii...

Read only

0 Likes
662

Hi abhi,

I appreciate your response

Kindly send me the screen shot with populated values.. and what changes have u made to the program if any...

because I have pasted the same code & my program remains on the selection screen only, callback routine is not called

Read only

0 Likes
662

Hi seema,

Please can you post the relevant code...

Regards

Abhii.....

Read only

0 Likes
662

CALLBACK_WA-LDBNODE = 'PERNR'.

CALLBACK_WA-GET = 'X'.

*CALLBACK_WA-GET_LATE = 'X'.

CALLBACK_WA-CB_PROG = SY-REPID.

CALLBACK_WA-CB_FORM = 'CALLBACK_LFB1'.

APPEND CALLBACK_WA TO CALLBACK.

SELTAB_WA-KIND = 'S'.

SELTAB_WA-SELNAME = 'KD_ABKRS'.

LOOP AT S_ABKRS.

MOVE-CORRESPONDING S_ABKRS TO SELTAB_WA.

APPEND SELTAB_WA TO SELTAB.

ENDLOOP.

CALL FUNCTION 'LDB_PROCESS'

EXPORTING

LDBNAME = 'PNP'

VARIANT = ' '

EXPRESSIONS = TEXPR

FIELD_SELECTION = FSEL

DYN_NODE_TYPES = DYN_NODE_TYPES

TABLES

CALLBACK = CALLBACK

SELECTIONS = SELTAB

EXCEPTIONS

LDB_NOT_REENTRANT = 1

LDB_INCORRECT = 2

LDB_ALREADY_RUNNING = 3

LDB_ERROR = 4

LDB_SELECTIONS_ERROR = 5

LDB_SELECTIONS_NOT_ACCEPTED = 6

VARIANT_NOT_EXISTENT = 7

VARIANT_OBSOLETE = 8

VARIANT_ERROR = 9

FREE_SELECTIONS_ERROR = 10

CALLBACK_NO_EVENT = 11

CALLBACK_NODE_DUPLICATE = 12

CALLBACK_NO_PROGRAM = 13

CALLBACK_NO_CBFORM = 14

DYN_NODE_NO_TYPE = 15

DYN_NODE_INVALID_TYPE = 16

OTHERS = 17.

IF SY-SUBRC NE 0.

WRITE: 'Exception with SY-SUBRC', SY-SUBRC.

ENDIF.

FORM CALLBACK_LFB1 USING NAME TYPE LDBN-LDBNODE

WA TYPE PERNR

EVT TYPE C

CHECK TYPE C.

CASE EVT.

WHEN 'G'.

WRITE: / WA-PERNR.

  • WHEN 'L'.

  • ULINE.

ENDCASE.

ENDFORM. "CALLBACK_PERNR