reporting service 中的权限问题

cooolchen 2009-11-17 05:09:49
我调用Sqlserver2008中的ReportService2005.asmx。
NetworkCredential nc = new NetworkCredential(username, password);
rs.Credentials = nc;
CatalogItem[] list = rs.ListChildren("/", true);


获得了一个CatalogItem[]数组我把它绑定到一个ListBox中,并在页面中放了一个ReportViewer控件来显示报表。
当我选择任一项,打开报表时,出现:

The request failed with HTTP status 401: Unauthorized.

...全文
194 14 打赏 收藏 转发到动态 举报
写回复
用AI写文章
14 条回复
切换为时间正序
请发表友善的回复…
发表回复
hery2002 2009-11-30
  • 打赏
  • 举报
回复
A Wrapper for Running SQL Server 2008 Reporting Services Reports Anonymously
http://www.codeproject.com/Articles/39007/A-Wrapper-for-Running-SQL-Server-2008-Reporting-Se.aspx
boboo_2000_0 2009-11-28
  • 打赏
  • 举报
回复
应该是ReportingServer用户权限问题,找了很久也没有解决,期待中。
yangdingyu8686 2009-11-28
  • 打赏
  • 举报
回复
http://topic.csdn.net/u/20090522/16/5c008129-0215-4c8c-b870-76c0d9f8b902.html
freefaery 2009-11-23
  • 打赏
  • 举报
回复
see
cooolchen 2009-11-18
  • 打赏
  • 举报
回复
继续顶


lfywy 2009-11-18
  • 打赏
  • 举报
回复
关注~~~~
hery2002 2009-11-18
  • 打赏
  • 举报
回复
[Quote=引用 6 楼 cooolchen 的回复:]
引用 5 楼 hery2002 的回复:
根据官网的资料和以前的经验,是你的Credentials用的不对,换如下试试.
C# codeReportingService rs=new ReportingService();
rs.Credentials= System.Net.CredentialCache.DefaultCredentials.
如果不提供用户名,那么我如何得到某一个用户能看到的报表呢?
[/Quote]
上面这段就是获取当前用户信息的,不需要特别指定用户名和密码.
而你前面使用的那种方式是Form认证方式,使用的特定用户名和密码,不是使用的window集成验证方式,
SQL Server 2005不支持匿名访问,貌似SSRS2008才支持.
cooolchen 2009-11-18
  • 打赏
  • 举报
回复
[Quote=引用 5 楼 hery2002 的回复:]
根据官网的资料和以前的经验,是你的Credentials用的不对,换如下试试.
C# codeReportingService rs=new ReportingService();
rs.Credentials= System.Net.CredentialCache.DefaultCredentials.
[/Quote]

如果不提供用户名,那么我如何得到某一个用户能看到的报表呢?
hery2002 2009-11-18
  • 打赏
  • 举报
回复
根据官网的资料和以前的经验,是你的Credentials用的不对,换如下试试.
ReportingService rs = new ReportingService();
rs.Credentials = System.Net.CredentialCache.DefaultCredentials.
cooolchen 2009-11-18
  • 打赏
  • 举报
回复
  • 打赏
  • 举报
回复
猜一个,提升访问iis用户的权限
孤独剑_LPZ 2009-11-17
  • 打赏
  • 举报
回复
没用过,帮顶
icelovey 2009-11-17
  • 打赏
  • 举报
回复
友情UP
--小F-- 2009-11-17
  • 打赏
  • 举报
回复
有请剪剪

590

社区成员

发帖
与我相关
我的任务
社区描述
提出问题
其他 技术论坛(原bbs)
社区管理员
  • community_281
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧