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

Number range problem in invoice

Former Member
0 Likes
673

Hi Experts,

i want to change the 'RV_BELEG' this number range object to 'ZRV_BELEG'.

in standard they hardcoded the number range object.

can any one suggest me how can i change the object?

any user exit is aavailble to change it in creation of invoice.

5 REPLIES 5
Read only

Former Member
0 Likes
614

In FM RV_INVOICE_DOCUMENT_ADD, Generally Number Range picked up for Invoice.

There is an Exit named as USEREXIT_NUMBER_RANGE.

So try to change through this FM, if it can solv your purpose.

Regds,

Anil

Read only

0 Likes
614

Hi Anil,

thanks for your answer,

i know abt that exit.

after that exit they hard coded the 'RV_BELEG' in the function madule. i want to change the 'RV_BELEG' to 'ZRV_BELEG'

CALL FUNCTION 'NUMBER_GET_NEXT'

EXPORTING

nr_range_nr = da_numki

object = 'RV_BELEG'

ignore_buffer = no_buffer

IMPORTING

returncode = ld_returncode

number = xvbrk-vbeln

EXCEPTIONS

interval_not_found = 1

number_range_not_intern = 2

object_not_found = 3

quantity_is_0 = 4

quantity_is_not_1 = 5

interval_overflow = 6

OTHERS = 99.

IF sy-subrc NE 0.

MESSAGE ID sy-msgid TYPE 'A' NUMBER sy-msgno

WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.

ELSE.

Read only

0 Likes
614

Hi Prashant,

It is not advisable to change the standard objects.

Can you provide information on your requirements, maybe I can help you.

Regards

Vijai

Read only

0 Likes
614

Prashant,

In that case you have to take access key from OSS Login.

Hope you are working for some client.

Get OSS login using there OSS login id and pwd after taking approval and get register the object of this FM on that.

SAP will provide you the Access key for the object.

Reggistering that you can change this FM.

But once you get access key, SAP will not be responsible for any type of issues regarding this object (FM0.

Regds,

Anil

Read only

brad_bohn
Active Contributor
0 Likes
614

Perhaps you should post the reason for wanting to do this. I can't think of any good reason why you should need to change the range object, which is exactly why SAP hard-coded the value there. Often, requirements like this come up because either the developer or functional person (or both) involved don't have enough experience to recommend the correct solution.