02-25-2009 8:58 AM
Dear Experts,
I want a new number range when creating a billing document. for this i created a new object ZNR in SNUM plant wise. and i am using FM - NUMBER_GET_NEXT in RV60AFZZ(USEREXIT_NUMBER_RANGE) . But how to map i am not able to under stand please help me.
wether i should write this code in other place.
Can any one.
Edited by: Charitha Reddy on Feb 25, 2009 10:09 AM
02-25-2009 10:49 AM
you have to check the Current number in particula number range. some times the current number range is 10, means the number already created, after that in customization they will set the current number range is 1, the 1 is already created, check the current number range and then proceed.
02-25-2009 10:56 AM
Hi,
CALL FUNCTION 'NUMBER_GET_NEXT'
EXPORTING
nr_range_nr = '01'
object = nr_object
IMPORTING
number = l_number
returncode = returncode
EXCEPTIONS
interval_not_found = 1
number_range_not_intern = 2
object_not_found = 3
quantity_is_0 = 4
interval_overflow = 5.
where nr_range_nr is the number and object is your object name, l_number is the generated number and return code.
Keerthi.