Skip to Content
author's profile photo Former Member
Former Member

Adding price list while adding item

Hi,

How do you add a price list while adding an Item in Item master data using DIAPI.

I see a PriceList propert, but how do i use it to set a price list for the item.

Sample code will be a great help.

I am using SBO 2004B.

Thanks.

Satish.

Message was edited by: Satish Dwevedi

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Sep 30, 2005 at 10:50 AM

    Hi Alexey,

    What is <price> in your code?

    Is it the price of the item or the price list for the item?

    Thanks,

    Satish.

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Sep 30, 2005 at 10:31 AM

    Hi Satish!

    SAPbobsCOM.Items	itmItem;
    SAPbobsCOM.Items_Prices itmPrices;
    ...
    if (itmItem.GetByKey(<ItemCode>))
    {
    	itmPrices = itmItem.PriceList;
    	for (int k=0; k<itmPrices.Count; k++)
    	{
    		itmPrices.SetCurrentLine(k);
    		itmPrices.Price = <price>
    	}
    
    	itmItem.Update();
    }

    HTH

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.