LookupTable.ReadLookupTablesMultiLangByUids 方法

获取多语言查阅表格和对应的代码掩码,指定列表的查阅表格 Guid。

命名空间:  WebSvcLookupTable
程序集:  ProjectServerServices(位于 ProjectServerServices.dll 中)

语法

声明
<SoapDocumentMethodAttribute("https://schemas.microsoft.com/office/project/server/webservices/LookupTable/ReadLookupTablesMultiLangByUids", RequestNamespace := "https://schemas.microsoft.com/office/project/server/webservices/LookupTable/",  _
    ResponseNamespace := "https://schemas.microsoft.com/office/project/server/webservices/LookupTable/",  _
    Use := SoapBindingUse.Literal, ParameterStyle := SoapParameterStyle.Wrapped)> _
Public Function ReadLookupTablesMultiLangByUids ( _
    ltUidList As Guid(), _
    autoCheckOut As Boolean _
) As LookupTableMultiLangDataSet
用法
Dim instance As LookupTable
Dim ltUidList As Guid()
Dim autoCheckOut As Boolean
Dim returnValue As LookupTableMultiLangDataSet

returnValue = instance.ReadLookupTablesMultiLangByUids(ltUidList, _
    autoCheckOut)
[SoapDocumentMethodAttribute("https://schemas.microsoft.com/office/project/server/webservices/LookupTable/ReadLookupTablesMultiLangByUids", RequestNamespace = "https://schemas.microsoft.com/office/project/server/webservices/LookupTable/", 
    ResponseNamespace = "https://schemas.microsoft.com/office/project/server/webservices/LookupTable/", 
    Use = SoapBindingUse.Literal, ParameterStyle = SoapParameterStyle.Wrapped)]
public LookupTableMultiLangDataSet ReadLookupTablesMultiLangByUids(
    Guid[] ltUidList,
    bool autoCheckOut
)

参数

  • ltUidList
    类型:[]

    多语言查阅表格 Guid 的数组。

  • autoCheckOut
    类型:System.Boolean

    如果为 true,则自动将签出指定的查找表中进行编辑。

返回值

类型:WebSvcLookupTable.LookupTableMultiLangDataSet

备注

To create a multilanguage lookup table for test purposes, see the example in CreateLookupTablesMultiLang or see the LookupTables section in Using the ProjTool Test Application.

警告

仅在测试安装的 Project Server 上创建测试查阅表格。

Project Server 权限

权限

说明

LogOn

允许用户登录到 Project Server。全局权限。

示例

In the following code fragment, ReadOneMultiLangLUT reads a lookup table specified by the lutUid parameter. LookupTableWS is an arbitrary name for a reference to the LookupTable Web service. To test the code, add it to a sample console application. For more information, see Project 2013 中基于 ASMX 的代码示例的先决条件.

using PSLibrary = Microsoft.Office.Project.Server.Library;
. . .
private const string LOOKUPTABLEWEBSERVICE = "_vti_bin/PSI/LookupTable.asmx";
private string baseUrl = "https://ServerName/ProjectServerName"/
private static LookupTableWS.LookupTable lookupTable =
    new LookupTableWS.LookupTable();

// Initialize the LookupTable Web service for Windows logon.
lookupTable.Url = baseUrl + LOOKUPTABLEWEBSERVICE;
lookupTable.Credentials = CredentialCache.DefaultCredentials;
. . . 
private void ReadOneMultiLangLUT (Guid lutUid)
{
    LookupTableWS.LookupTableMultiLangDataSet lutMultiLang =
        new LookupTableWS.LookupTableMultiLangDataSet();

    if (lutUid == Guid.Empty)
        lutUid = new Guid("1796cacc-5406-4c93-80cb-e7fb1271d32a");
    Guid[] lutUids = { lutUid };

    lutMultiLang = lookupTable.ReadLookupTablesMultiLangByUids(lutUids, false);
    string xmlFile = @"C:\Project\DataSets\MultilanguageLookupTableDataSet.xml";
    SaveDataSetToXml(lutMultiLang, xmlFile);
}
// Save the DataSet for examination.
private void SaveDataSetToXml(DataSet ds, string filePathName)
{
    ds.WriteXml(filePathName);
}

另请参阅

引用

LookupTable 类

LookupTable 成员

WebSvcLookupTable 命名空间