Description
Updates an existing department.
The data for the department, including the key of the department to be updated, is contained in the Department object passed to the method. To update a department, you must first retrieve it using the GetDepartment method.
Syntax
Parameters
Example
| Updating a department (C#) | Copy Code |
|---|
DepartmentParams getLine; SAPbobsCOM.Department updateLine; getLine = (DepartmentParams)oDeptSrv.GetDataInterface(DepartmentsServiceDataInterfaces.dsDepartmentParams); // Please note that the Code should of an existing record. getLine.Code = 10; updateLine = oDeptSrv.GetDepartment(getLine); updateLine.Name = "A1"; updateLine.Description = "All in One"; oDeptSrv.UpdateDepartment(updateLine);
|
|
See Also