ReadCustomFieldsByEntity Method

CustomFields.ReadCustomFieldsByEntity Method

Office 2010

Gets all of the enterprise custom fields for the specified entity (project, resource, or task).

Namespace:  [CustomFields Web service]
Service reference: http://ServerName:32843/[Project Service Application GUID]/PSI/CustomFields.svc
Web service reference: http://ServerName/ProjectServerName/_vti_bin/PSI/CustomFields.asmx?wsdl

[SoapDocumentMethodAttribute("", RequestNamespace = "", 
	ResponseNamespace = "", 
	Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public CustomFieldDataSet ReadCustomFieldsByEntity(
	Guid entityUid


Type: System.Guid
The GUID of the custom field project, resource, or task entity.

Return Value

Type: [CustomFields Web service].CustomFieldDataSet
The CustomFieldDataSet contains all custom field data for the project, resource, or task that is specified by the entityUid parameter.

To get all of the resource custom fields, for example, use the resource entity GUID from the EntityCollection.Entities property in the Microsoft.Office.Project.Server.Library assembly.


The ReadCustomFieldsByEntity method ignores the locale setting of the computer running Project Server. The ReadCustomFieldsByEntity2(Guid) method returns locale-dependent values for formulas that calculate custom fields and graphical indicators.

Project Server Permissions




Allows a user to connect to the Project Server database from Project Professional. Global permission.


Allows a user to modify the definitions of enterprise custom fields and lookup table values. Global permission.


Allows a user to manage Project Server users and groups. Global permission.


Allows a user to create a project. Global permission.


Allows a user to view resource allocation data. Global permission.


Allows the user to manage workflows. Global permission.

The following code fragment returns a CustomFieldDataSet with all of the CustomFieldDataSet.CustomFieldsRow objects for resource custom fields. [CustomFields Web service] is the arbitrary name of a reference to the CustomFields.asmx web service.

using PSLibrary = Microsoft.Office.Project.Server.Library;
. . .
public static WebSvcCustomFields.CustomFields customFields =
    new WebSvcCustomFields.CustomFields();
. . .
string resourceEntity = PSLibrary.EntityCollection.Entities.ResourceEntity.UniqueId;

WebSvcCustomFields.CustomFieldDataSet cfDs = customFields.ReadCustomFieldsByEntity(
    new Guid(resourceEntity));
. . .

Community Additions

© 2015 Microsoft