📚 SAP Business One SDK Help

AddSalesOpportunityInterestSetup Method
See Also  Example
pISalesOpportunityInterestSetup
The data for the new interest.

Description

Adds an interest.

Syntax

Visual Basic
Public Function AddSalesOpportunityInterestSetup( _
   ByVal pISalesOpportunityInterestSetup As SalesOpportunityInterestSetup _
) As SalesOpportunityInterestSetupParams

Parameters

pISalesOpportunityInterestSetup
The data for the new interest.

Return Type

Contains the key (Num) of the new interest.

Example

Adding a sales opportunity interest (C#)Copy Code
SalesOpportunityInterestSetup interest = interestService.GetDataInterface( 
    SalesOpportunityInterestsSetupServiceDataInterfaces.soissSalesOpportunityInterestSetup) as SalesOpportunityInterestSetup; 
 
interest.Description = "book"; 
interest.Sort = 1000; 
Console.WriteLine("Add a new interest: Description: " + interest.Description + "  Sort:" + interest.Sort.ToString()); 
try 

    interestService.AddSalesOpportunityInterestSetup(interest); 

catch (Exception e) 

    PrintExceptionMessage(e); 

See Also