EnterpriseOutlineCodesHierarchical Method

Description

The PDS gets from Microsoft Office Project Server 2003 the hierarchical enterprise outline code structures and the code mask for fields of the specified type.

Syntax

<Request>
   <EnterpriseOutlineCodesHierarchical>
      <CodeType></CodeType>
      <CodeFields>
         <CodeField></CodeField>
      </CodeFields>
   </EnterpriseOutlineCodesHierarchical>
</Request>

Parameters

CodeField

Optional. If CodeField is included in the request, EnterpriseCustomFields 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 fields
1 Resource enterprise fields
2 Task enterprise fields

Return Value

If the code list request is successful, EnterpriseOutlineCodesHierarchical returns a successful HRESULT and STATUS, the hierarchical value lists, and the code mask for the specified fields.

If for any reason one of the requested code value lists cannot be found or any 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>0</HRESULT>
   <STATUS>0</STATUS>
   <UserName>Administrator</UserName>
   <OutlineCodes>
      <MaxUsedCodeUID></MaxUsedCodeUID>
      <OutlineCode>
         <UID></UID>
         <Name></Name>
         <Warpable></Warpable>
         <SelectLeafOnly></SelectLeafOnly>
         <SelectionRequired></SelectionRequired>
         <Nodes>
            <Node>
               <UID></UID>
               <Description/>
               <Value></Value>
               <Nodes>
                  <Node>
                     <UID></UID>
                     <Description/>
                     <Value></Value>
                  </Node>
                  <Node>
                     <UID></UID>
                     <Description/>
                     <Value></Value>
                  </Node>
               </Nodes>
            </Node>
         </Nodes>
         <Masks>
            <Mask>
               <Level></Level>
               <Type></Type>
               <Length></Length>
               <Separator></Separator>
            </Mask>
         </Masks>
      </OutlineCode>
   </OutlineCodes>
</Reply>

Note Warpable returns 0 or 32, where 0 is No and 32 is Yes, when the Enterprise Global template is saved using Project Professional. This is different from Warpable in EnterpriseOutlineCodeUpdate, which is set to 0 or 1. This is done for consistency with existing Microsoft Project 2002 methods.

However, if the PDS has directly edited that outline code in Enterprise Global, Warpable returns 1 for Yes.

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.