Description
Adds a branch.
Syntax
Parameters
Return Type
Contains the key (Code) of the new branch.
Example
| Adding a branch (C#) | Copy Code |
|---|
public void add() { try { BranchesService oBranchSrv; oBranchSrv = (BranchesService)(MainModule.oCmpSrv.GetBusinessService(ServiceTypes.BranchesService)); SAPbobsCOM.Branch addLine; addLine = (SAPbobsCOM.Branch)oBranchSrv.GetDataInterface(BranchesServiceDataInterfaces.bsBranch); //full addition addLine.Name = "X"; addLine.Description = "X Branch"; oBranchSrv.AddBranch(addLine); } catch (Exception ex) { Interaction.MsgBox(ex.Message, (Microsoft.VisualBasic.MsgBoxStyle)(0), null); } }
|
|
See Also