Share via


EnterpriseOutlineCodes Method

Description

The PDS gets from Microsoft Office Project Server 2003 the active enterprise outline code structures (the mask and the value lists) for fields of the specified type.

Syntax

<Request>
   <EnterpriseOutlineCodes>
      <CodeType></CodeType>
      <CodeFields>
         <CodeField></CodeField>
      </CodeFields>
   </EnterpriseOutlineCodes>
</Request>

Parameters

CodeField

Optional. If CodeField is included in the request, then EnterpriseOutlineCodes returns only fields that correspond to the CodeField parameters; CodeType is ignored, even if it is included. Multiple CodeField parameters are valid.

Conversion values for CodeField are listed in Field ID Values for Enterprise Custom Fields.

CodeType

Optional. If no parameters are given, then CodeType 0 is the default. Valid CodeType values are as follows:

CodeType Description
0 Project enterprise outline codes
1 Resource enterprise outline codes
2 Task enterprise outline codes

Note   Any fields that do not contain data should be removed from the request.

Return Value

If the code list request is successful, then EnterpriseOutlineCodes returns a successful HRESULT and STATUS and the value lists for the specified fields.

If any one of the requested code fields is not available, the entire request fails. The return includes each code field that failed and an error code.

The reply also includes MaxUsedCodeUID for each outline code requested, to provide all of the information necessary to programmatically edit an outline code value list.

<Reply>
   <HRESULT></HRESULT>
   <STATUS></STATUS>
   <UserName></UserName>
   <OutlineCodes>
      <MaxUsedCodeUID></MaxUsedCodeUID>
      <OutlineCode>
         <UID></UID>
         <Name></Name>
         <Warpable></Warpable>
         <SelectLeafOnly></SelectLeafOnly>
         <SelectionRequired></SelectionRequired>
         <Values>
            <Value>
               <UID></UID>
               <ParentUID></ParentUID>
               <Description/>
               <Value></Value>
               <ValueFull></ValueFull>
            </Value>
         </Values>
         <Masks>
            <Mask>
               <Level></Level>
               <Type></Type>
               <Length></Length>
               <Separator></Separator>
            </Mask>
         </Masks>
      </OutlineCode>
   </OutlineCodes>
</Reply>

Remarks

The PDS checks Project Server security to determine whether the logged-on user has valid Project Server permissions.

The PDS returns error code 501 (rsCodeTypeInvalid) if a request includes an invalid CodeType. For an invalid CodeField, the PDS returns error code 42 (rsEnterpriseCustomFieldUIDInvalid). An empty field, such as <CodeType></CodeType>, is invalid.