ProjectPlans_ExportMSProject Operation

Applies to QAComplete 14.3, last modified on February 19, 2024

Exports the specified project plan from a project in QAComplete to Microsoft Project.

Requirements

  • The user must belong to a security group that has the Read privilege for Project Plan Maintenance (Project Manager).

  • The plug-in to MS Project that allows importing project plans to and exporting them from Microsoft Project must be installed.

Parameters

The operation uses the following parameters:

AuthenticationData  :  AuthenticationData, required

An AuthenticationData object containing the login information and the ID of project whose plan you want to export.

ProjPlanId  :  integer, required

The ID of the project plan you want to export.

Result

The ProjectPlan object that describes the exported project plan.

Example

Sample Code

C#

string login = "[email protected]";
string password = "p@ssword";

ServiceSoapClient service = new ServiceSoapClient();

// Prepare AuthenticationData
LoginInfo loginInfo = service.GetLoginInfo("", login, password);
AuthenticationData authData = new AuthenticationData();
authData.AppCode = loginInfo.AppCode;
authData.UserId = loginInfo.UserId;
authData.PassCode = password;
authData.DeptId = loginInfo.DeptId;
authData.ProjId = loginInfo.ProjId;

int projPlanId = 5;

try
{
  ProjectPlan plan = service.ProjectPlans_ExportMSProject(authData, projPlanId);
}
catch (FaultException e)
{
  MessageFault msg = e.CreateMessageFault();
  string error = msg.GetReaderAtDetailContents().GetAttribute("Text");
  Console.WriteLine(error);
}

Java

String login = "[email protected]";
String password = "p@ssword";

ServiceSoap service = new Service().getServiceSoap12();

// Prepare AuthenticationData
LoginInfo loginInfo = service.getLoginInfo("", login, password);
AuthenticationData authData = new AuthenticationData();
authData.setAppCode(loginInfo.getAppCode());
authData.setUserId(loginInfo.getUserId());
authData.setPassCode(password);
authData.setDeptId(loginInfo.getDeptId());
authData.setProjId(loginInfo.getProjId());

int projPlanId = 5;

try
{
  ProjectPlan plan = service.projectPlansExportMSProject(authData, projPlanId);
}
catch (Exception e)
{
  e.printStackTrace();
}

Sample Request XML

POST /psws/psws.asmx HTTP/1.1
Host: myteam.mysite.com
Content-Type: text/xml; charset=utf-8
Content-Length: 527 {Insert an appropriate value here}
SOAPAction: "http://www.pragmaticsw.com/ProjectPlans_ExportMSProject"
 

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <ProjectPlans_ExportMSProject xmlns="http://www.pragmaticsw.com/">
      <AuthenticationData>
        <AppCode>agSP</AppCode>
        <DeptId>8162</DeptId>
        <ProjId>11873</ProjId>
        <UserId>24661</UserId>
        <PassCode>p@ssword</PassCode>
      </AuthenticationData>
      <ProjPlanId>5</ProjPlanId>
    </ProjectPlans_ExportMSProject>
  </soap:Body>
</soap:Envelope>

SOAP 1.2

POST /psws/psws.asmx HTTP/1.1
Host: myteam.mysite.com
Content-Type: application/soap+xml; charset=utf-8
Content-Length: 535 {Insert an appropriate value here}
 

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <ProjectPlans_ExportMSProject xmlns="http://www.pragmaticsw.com/">
      <AuthenticationData>
        <AppCode>agSP</AppCode>
        <DeptId>8162</DeptId>
        <ProjId>11873</ProjId>
        <UserId>24661</UserId>
        <PassCode>p@ssword</PassCode>
      </AuthenticationData>
      <ProjPlanId>5</ProjPlanId>
    </ProjectPlans_ExportMSProject>
  </soap12:Body>
</soap12:Envelope>

Sample Response XML

HTTP/1.1 200 OK
Content-Type: text/xml; charset=utf-8
Content-Length: 1774 {The server returns an appropriate value here}
 

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
  <soap:Body>
    <ProjectPlans_ExportMSProjectResponse xmlns="http://www.pragmaticsw.com/">
      <ProjectPlans_ExportMSProjectResult>
        <ProjPlanId>2</ProjPlanId>
        <Name>Application BETA Schedule</Name>
        <OwnerUserId>24661</OwnerUserId>
        <OwnerName>Doe, John</OwnerName>
        <AssigneeUserId>24661</AssigneeUserId>
        <AssignedToName>Doe, John</AssignedToName>
        <StatusCode>Active</StatusCode>
        <ActPctComplete>15</ActPctComplete>
        <Tasks>
          <PPTask>
            <TaskName>Test new input controls</TaskName>
            <IsParent>N</IsParent>
            <Description>New task description.</Description>
            <Indent>3</Indent>
            <EstStart>2014-07-18T08:00:00</EstStart>
            <EstFinish>2014-07-21T23:59:00</EstFinish>
            <AssigneeUserId>24661</AssigneeUserId>
            <AssignedToName>Doe, John</AssignedToName>
            <ActStart>0001-01-01T00:00:00</ActStart>
            <PredNum>5</PredNum>
            <SeqNum>6</SeqNum>
            <Work>60</Work>
          </PPTask>
          <PPTask>
            <TaskName>Test new list controls</TaskName>
            <IsParent>N</IsParent>
            <Description>New task description.</Description>
            <Indent>3</Indent>
            <EstStart>2014-07-22T08:00:00</EstStart>
            <EstFinish>2014-07-23T23:59:00</EstFinish>
            <AssigneeUserId>24661</AssigneeUserId>
            <AssignedToName>Doe, John</AssignedToName>
            <ActStart>0001-01-01T00:00:00</ActStart>
            <PredNum>6</PredNum>
            <SeqNum>7</SeqNum>
            <Work>120</Work>
          </PPTask>
        </Tasks>
        <Resources>
          <PPResource>
            <UserId>24661</UserId>
            <PersonName>Doe, John</PersonName>
            <StandardRate>0</StandardRate>
          </PPResource>
          <PPResource>
            <UserId>24667</UserId>
            <PersonName>Doe, Jane</PersonName>
            <StandardRate>0</StandardRate>
          </PPResource>
        </Resources>
      </ProjectPlans_ExportMSProjectResult>
    </ProjectPlans_ExportMSProjectResponse>
  </soap:Body>
</soap:Envelope>

SOAP 1.2

HTTP/1.1 200 OK
Content-Type: application/soap+xml; charset=utf-8
Content-Length: 1784 {The server returns an appropriate value here}
 

<?xml version="1.0" encoding="utf-8"?>
<soap12:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap12="http://www.w3.org/2003/05/soap-envelope">
  <soap12:Body>
    <ProjectPlans_ExportMSProjectResponse xmlns="http://www.pragmaticsw.com/">
      <ProjectPlans_ExportMSProjectResult>
        <ProjPlanId>2</ProjPlanId>
        <Name>Application BETA Schedule</Name>
        <OwnerUserId>24661</OwnerUserId>
        <OwnerName>Doe, John</OwnerName>
        <AssigneeUserId>24661</AssigneeUserId>
        <AssignedToName>Doe, John</AssignedToName>
        <StatusCode>Active</StatusCode>
        <ActPctComplete>15</ActPctComplete>
        <Tasks>
          <PPTask>
            <TaskName>Test new input controls</TaskName>
            <IsParent>N</IsParent>
            <Description>New task description.</Description>
            <Indent>3</Indent>
            <EstStart>2014-07-18T08:00:00</EstStart>
            <EstFinish>2014-07-21T23:59:00</EstFinish>
            <AssigneeUserId>24661</AssigneeUserId>
            <AssignedToName>Doe, John</AssignedToName>
            <ActStart>0001-01-01T00:00:00</ActStart>
            <PredNum>5</PredNum>
            <SeqNum>6</SeqNum>
            <Work>60</Work>
          </PPTask>
          <PPTask>
            <TaskName>Test new list controls</TaskName>
            <IsParent>N</IsParent>
            <Description>New task description.</Description>
            <Indent>3</Indent>
            <EstStart>2014-07-22T08:00:00</EstStart>
            <EstFinish>2014-07-23T23:59:00</EstFinish>
            <AssigneeUserId>24661</AssigneeUserId>
            <AssignedToName>Doe, John</AssignedToName>
            <ActStart>0001-01-01T00:00:00</ActStart>
            <PredNum>6</PredNum>
            <SeqNum>7</SeqNum>
            <Work>120</Work>
          </PPTask>
        </Tasks>
        <Resources>
          <PPResource>
            <UserId>24661</UserId>
            <PersonName>Doe, John</PersonName>
            <StandardRate>0</StandardRate>
          </PPResource>
          <PPResource>
            <UserId>24667</UserId>
            <PersonName>Doe, Jane</PersonName>
            <StandardRate>0</StandardRate>
          </PPResource>
        </Resources>
      </ProjectPlans_ExportMSProjectResult>
    </ProjectPlans_ExportMSProjectResponse>
  </soap12:Body>
</soap12:Envelope>

See Also

ProjectPlans_GetListOfProjectPlans
ProjectPlans_GetListOfResources
ProjectPlans_ImportMSProject
Project Plan Operations
Project Operations
SOAP API Reference

Highlight search results