Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我使用 SSRS 2005 开发了一份报告。报告有 5 个参数。其中 4 个将被显示并由用户选择,1 个(比如说 ID)需要隐藏。
我想从我的 ASP.NET 应用程序中传递 ID 参数的值,这将是登录用户的名称。
您可以尝试使用此代码
var report = new LocalReport(); report .ReportPath = Server.MapPath("~/Path/To/Report.rdlc"); ReportParameter param= new ReportParameter("Name", "Value"); report .SetParameters(new ReportParameter[] { param});