2010-03-14 39 views
4

如何通过ID找到SSRS中的项目?我试图用另一个发现结果返回的ID,一个新的GUID字符串和小的随机字符串所有这些都返回相同的错误:查找项目是SSRS通过ID

The ID field has a value that is not valid. ---> Microsoft.ReportingServices.Diagnostics.Utilities.InvalidElementException: The ID field has a value that is not valid.

下面是代码:

var request = new FindItemsRequest 
     { 
      Conditions = new[] { new SearchCondition { Name = "ID", Value = "test"} }, 
      Folder = "/" 
     }; 
     return _ssrsService 
      .FindItems(request) 
      .Items 

我m使用SSRS 2005.

回答

1

很确定这不能通过SSRS服务完成。结束查找所有对象,然后使用LINQ筛选到我需要的ID。

1

FindItems方法的MS文档说:

Applications that use FindItems typically accept user input for specific properties and property values. The searchable properties are Name, Description, CreatedBy, CreationDate, ModifiedBy, and ModifiedDate. The items that are returned are only those for which a user has Read Properties permission.