Third Step:modify the source code to control use different number range for different sale organiztion3.1 you can use se38 to open source code MV45AFZZ and find the form userexit_number_range.*———————————————————————** FORM USEREXIT_NUMBER_RANGE **———————————————————————** This userexit can be used to determine the numberranges for ** the internal document number. ** ** US_RANGE_INTERN – internal number range ** ** This form is called from form BELEG_SICHERN ** **———————————————————————*form userexit_number_range using us_range_intern.

3.2 change the source code as the following *———————————————————————** FORM USEREXIT_NUMBER_RANGE **———————————————————————** This userexit can be used to determine the numberranges for ** the internal document number. ** ** US_RANGE_INTERN – internal number range ** ** This form is called from form BELEG_SICHERN ** **———————————————————————*form userexit_number_range using us_range_intern.

to make it more flexible you might use a little add-on customizing table to read the correct number range ID from. In our case, this table uses sales organisation and document type to determine the number range: