March 25, 2011 at 7:35 am
The drop downs in my report viewer just show what looks like a image that is not there. I know the credentials work on this server. I don't think it is a permission error. Any ideas?
Firebug gives me 404 errors on these:
Here is my code:
private void viewReport(string Report_Short_Name)
{
NameValueCollection NVC = (NameValueCollection)System.Configuration.ConfigurationManager.GetSection("SecureSettings");
ReportViewer1.ServerReport.ReportServerCredentials = new ReportServerCredentials(NVC.Get(0), NVC.Get(1), "");
ReportViewer1.ServerReport.ReportServerUrl = m_ReportServerUrl;
ReportViewer1.ServerReport.ReportPath = String.Format("{0}{1}", m_ReportDir, Report_Short_Name);
ReportViewer1.ServerReport.Refresh();
}
private void viewReportParms(string Report_Short_Name)
{
//add Parms Here
ReportViewer1.ServerReport.ReportServerUrl = m_ReportServerUrl;
ReportViewer1.ServerReport.ReportPath = String.Format("{0}{1}", m_ReportDir, Report_Short_Name);
ReportViewer1.ServerReport.Refresh();
}
public class ReportServerCredentials : IReportServerCredentials
{
private string _userName;
private string _password;
private string _domain;
public ReportServerCredentials(string userName,
string password, string domain)
{
_userName = userName;
_password = password;
_domain = domain;
}
public WindowsIdentity ImpersonationUser
{
get
{
// Use default identity.
return null;
}
}
public ICredentials NetworkCredentials
{
get
{
// Use default identity.
return new NetworkCredential(_userName, _password, _domain);
}
}
public bool GetFormsCredentials(out Cookie authCookie, out string user,
out string password, out string authority)
{
// Do not use forms credentials to authenticate.
authCookie = null;
user = password = authority = null;
return false;
}
March 25, 2011 at 8:20 am
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply