Application Development 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: 

Adding a new material while saving the Invoice in SAP SD module

Former Member
0 Kudos

Hello,

We have a requirement where we need to create a Invoice with reference to sales order through VF01.

While saving the Invoice a new line item (Material) must be added in the invoice through some Exit/BADI/Enhancement.

We have written the code in the Enhancement spot of the include LV60AB03.

The new line item is getting added when we enter the sales order in the initial screen but not getting saved while saving the invoice.

When we check the invoice in VF03 the new material does not exist.

Also we are getting an error when invoice is created.

Document & has been saved (Pricing error)

Message VF071.

Could anybody please provide information on how to add the new item/material at the time of saving the invoice with the correct pricing data?

Thanks & Regards

Abdul samee

6 REPLIES 6

madhu_vadlamani
Active Contributor
0 Kudos

Hi Abdul,

Then how that will come in pricing.Did the functional people check with sales bom concept.What is the business requirement to add this at invoice.

Regards,

Madhu.

0 Kudos

Hello Madhu,

Functional people have created a new pricing condition type for the new material and a new pricing routine.

The business requirement is that we need to charge an invoice fee for some customers.

To represent this invoice fee, we have created a dummy material and have maintained the Price for this material with a new condition type.

So whenever we create a invoice (with reference to sales order), this new material must be added at the time of saving the invoice.

We have written the code in the Enhancement spot of the include LV60AB03.

Invoice is created normally but the new material is not getting saved.

0 Kudos

Hi Abdul,

Did you try with free goods concept.

Regards,

Madhu.

0 Kudos

Hello Madhu,

NO

It is related to Sales invoice creation.

0 Kudos

Hi Abdul,

Yes.As i know you can not add line item in sales invoice directly.It should flow from sales order.

Regards,

Madhu.

Hi Abdul,

Can you please let me know if you are able to get this functionality? I have a requirement for similar functionality to add new material into Invoice at the time of creation. I tried to search for user exits as well.

Can you please help me to resolve this? Can you tell me what is the user exit you have used?

Regards,

Suresh Linga.