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

Create Inbound Delivery with Reference to PO using Serial Numbers

Former Member
0 Likes
1,138

I guys.

I didn't find any BAPI to create an Inbound Delivery with Reference to PO using Serial Numbers so I've made a Function Module with BDCData.

...

LOOP AT serial.

ADD 1 TO ld_count.

ld_value = serial-sernr.

CONCATENATE 'RIPW0-SERNR(' ld_count ')' INTO ld_field.

PERFORM bdc_field USING ld_field ld_value.

ENDLOOP.

...

This works fine for 10 entries, but when I'm trying to use 1000 entries in serial Internal Table I'm getting the error: Screen 0000 is too large for internal batch input area - Message no. 00379.

Please note that my issue is the Serial numbers, so don't answer me please with BAPIs that doesnt allow me to deal with this.

Any idea?

Thanks in advance,

Nuno

The program gives the error when I'm trying to use 20 serial numbers. However, when I'm using only 19 it runs OK. Actually, 19 is the number of visible entries that the program displays in the screen.

I will try to put the bdcdata for a "page down" instruction at each 19 entries. Let's hope this solve my problem, despite of being a really ugly sollution.

4 REPLIES 4
Read only

Former Member
0 Likes
977

Have you checked the long text for this message?

Rob

Read only

0 Likes
977

The program gives the error when I'm trying to use 20 serial numbers. However, when I'm using only 19 it runs OK. Actually, 19 is the number of visible entries that the program displays in the screen.

I will try to put the bdcdata for a "page down" instruction at each 19 entries. Let's hope this solve my problem, despite of being a really ugly sollution.

Read only

0 Likes
977

Hi ,

Check that V_COUNT and if it is GT the 19 do the page down, and make the V_COUNT to 2 , so that last number i.e 19th position serial number will come and sit in the 1st postion of the 2nd page.

Regards,

Bharani

Read only

0 Likes
977

As I expect, it solved my problem. It's not pretty, but it works...

PERFORM bdc_dynpro USING 'SAPLIPW1' '0200'.

PERFORM bdc_field USING 'BDC_CURSOR' 'RIPW0-SERNR(01)'.

DATA: ld_valor(4) TYPE n,

ld_next,

ld_tabix TYPE sy-tabix.

LOOP AT serial.

ld_tabix = sy-tabix.

IF ld_next = 'X'.

CLEAR ld_next.

ld_count = 2.

ELSE.

ADD 1 TO ld_count.

ENDIF.

ld_value = serial-sernr.

CONCATENATE 'RIPW0-SERNR(' ld_count ')' INTO ld_field.

PERFORM bdc_field USING ld_field ld_value.

ld_valor = ld_tabix + 17.

ld_valor = ld_valor MOD 18.

IF ld_tabix NE 1 AND ( ld_tabix EQ 19 OR ld_valor EQ 0 ).

ld_next = 'X'.

PERFORM bdc_field USING 'BDC_OKCODE' '=PNPG'.

PERFORM bdc_dynpro USING 'SAPLIPW1' '0200'.

PERFORM bdc_field USING 'BDC_CURSOR' 'RIPW0-SERNR(01)'.

ENDIF.

ENDLOOP.

PERFORM bdc_field USING 'BDC_OKCODE' '=RWS'.