我在本机已经实现了报表,而且没有引用Report WebService也能在程序中运行,但是报表文档要求要先建立认证,再生成报表!不知道为什么?在建立认证时出现一下问题,请帮忙!
在MSDN文档里有这个说明如下:
using System;
using System.Web.Services.Protocols;class Sample
{
public static void Main()
{
ReportingService rs = new ReportingService();
rs.Credentials = System.Net.CredentialCache.DefaultCredentials; // Create the property to retrieve.
Property retrieveProp = new Property();
retrieveProp.Name = "Description";
Property[] props = new Property[1];
props[0] = retrieveProp; try
{
Property[] properties = rs.GetProperties("/Samples/Company Sales", props); foreach (Property prop in properties)
{
// Writes the description to the console.
Console.WriteLine(prop.Value);
}
} catch ( SoapException e )
{
Console.WriteLine( e.Detail.InnerXml.ToString() );
}
}
}
它提示错误在以下这句话,是路径的问题:
Property[] properties = rs.GetProperties("/Samples/Company Sales", props);
我的报表是在Http://localhost/reportservice里部署的一个ReportSale表,
请问如何获得这个路径?谢谢!
在MSDN文档里有这个说明如下:
using System;
using System.Web.Services.Protocols;class Sample
{
public static void Main()
{
ReportingService rs = new ReportingService();
rs.Credentials = System.Net.CredentialCache.DefaultCredentials; // Create the property to retrieve.
Property retrieveProp = new Property();
retrieveProp.Name = "Description";
Property[] props = new Property[1];
props[0] = retrieveProp; try
{
Property[] properties = rs.GetProperties("/Samples/Company Sales", props); foreach (Property prop in properties)
{
// Writes the description to the console.
Console.WriteLine(prop.Value);
}
} catch ( SoapException e )
{
Console.WriteLine( e.Detail.InnerXml.ToString() );
}
}
}
它提示错误在以下这句话,是路径的问题:
Property[] properties = rs.GetProperties("/Samples/Company Sales", props);
我的报表是在Http://localhost/reportservice里部署的一个ReportSale表,
请问如何获得这个路径?谢谢!
解决方案 »
- Paypal 交易号不一致
- 执行一个服务端按钮事件的进度条显示....
- CheckBox 多选框怎样取id值
- 没分了,,给大家看一个问题,,
- 各位急救啊,谢谢了
- VS2008的解决方案
- ************** 我用javascript特效动态加了很多<input type='text' name='JHL"+countRow+"' maxlength='8' size='5'>, 为什么只能保
- 调试时出现如下错误
- 紧急,请问谁知道rational rose的免费下载地址
- 急,简单的问题,在线等
- 我遇到一个问题。求救
- [<a target="_blank" href="WebForm2.aspx">签写留言</a>]中target="_blank"是什么意思?
eg:your report in the folder "Test",and the reportname is "testReport"
the the path is :
"/Test/testReport"
you should read more related articles.
in this occasion:
you should upload your reports into report server