Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 415201
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T18:21:28+00:00 2026-05-12T18:21:28+00:00

I am having difficulties getting the following to export. I am running CR2008SP2 and

  • 0

I am having difficulties getting the following to export. I am running CR2008SP2 and ASP.NET 3.5 against an Oracle 10g database.

If i do not set any of the parameters, then the page works great, and pumps out a pdf(well, except for the fact that because the parameters weren’t specified, its not really the data i want. but theres no errors). If i do set the parameters, then i get the following error–

Logon failed.
Details:  [Database Vendor Code: 1005 ]Logon failed.
Details:  [Database Vendor Code: 1005 ]Error in File file {AA9A7083-D19D-454F-8454-B6CA36756895}.rpt:
Unable to connect: incorrect log on parameters.
Details:  [Database Vendor Code: 1005 ]


[COMException (0x8004100f): Logon failed.
Details:  [Database Vendor Code: 1005 ]
Logon failed.
Details:  [Database Vendor Code: 1005 ]
Error in File file {AA9A7083-D19D-454F-8454-B6CA36756895}.rpt:
Unable to connect: incorrect log on parameters.
Details:  [Database Vendor Code: 1005 ]]
   CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext) +0
   CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext) +531

[LogOnException: Logon failed.
Details:  [Database Vendor Code: 1005 ]
Logon failed.
Details:  [Database Vendor Code: 1005 ]
Error in File file {AA9A7083-D19D-454F-8454-B6CA36756895}.rpt:
Unable to connect: incorrect log on parameters.
Details:  [Database Vendor Code: 1005 ]]
   CrystalDecisions.ReportAppServer.ConvertDotNetToErom.ThrowDotNetException(Exception e) +1177
   CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext) +633
   CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext) +1178
   CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToStream(ExportOptions options) +154
   CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToHttpResponse(ExportOptions options, HttpResponse response, Boolean asAttachment, String attachmentName) +218
   CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToHttpResponse(ExportFormatType formatType, HttpResponse response, Boolean asAttachment, String attachmentName) +247
   AMR.RptParameter4.LoadReport(ReportState rptState) in c:\Documents and Settings\pp47067\My Documents\AMR 2\Development\AMR_TESTING_01\AMR\RptParameter4.aspx.cs:99
   AMR.RptParameter4.btnyclick(Object sender, EventArgs e) in c:\Documents and Settings\pp47067\My Documents\AMR 2\Development\AMR_TESTING_01\AMR\RptParameter4.aspx.cs:168
   System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565

here is the code i used

public void LoadReport()
{
                    crReportDocument = new ReportDocument();


                    connectionInfo = new ConnectionInfo();
                    ParameterField paramField1 = new ParameterField();
                    ParameterField paramField2 = new ParameterField();
                    ParameterField paramField3 = new ParameterField();
                    ParameterField paramField4 = new ParameterField();
                    ParameterFields paramFields = new ParameterFields();
                    ParameterDiscreteValue paramDiscreteValue1 = new ParameterDiscreteValue();
                    ParameterDiscreteValue paramDiscreteValue2 = new ParameterDiscreteValue();
                    ParameterDiscreteValue paramDiscreteValue3 = new ParameterDiscreteValue();
                    ParameterDiscreteValue paramDiscreteValue4 = new ParameterDiscreteValue();
                    //p1
                    paramField1.Name = "Siebel Position";
                    paramDiscreteValue1.Value = txtAvailPos.Text;
                    paramField1.CurrentValues.Add(paramDiscreteValue1);
                    paramFields.Add(paramField1);

                    //p2
                    paramField2.Name = "DETAIL_LEVEL";
                    paramDiscreteValue2.Value = ddlDetailLvl.SelectedValue;
                    paramField2.CurrentValues.Add(paramDiscreteValue2);
                    paramFields.Add(paramField2);

                    //p3
                    paramField3.Name = "RPT_MONTH";
                    paramDiscreteValue3.Value = ddlMonth.SelectedValue;
                    paramField3.CurrentValues.Add(paramDiscreteValue3);
                    paramFields.Add(paramField3);
                    //p4
                    paramField4.Name = "RPT_YEAR";
                    paramDiscreteValue4.Value = txtYear.Text;
                    paramField4.CurrentValues.Add(paramDiscreteValue4);
                    paramFields.Add(paramField4);

    //setting these parameters is what will cause login issues
    //crReportDocument.SetParameterValue("Siebel Position", txtAvailPos.Text);
                    //crReportDocument.SetParameterValue("DETAIL_LEVEL", ddlDetailLvl.SelectedValue);
                    //crReportDocument.SetParameterValue("RPT_MONTH", ddlMonth.SelectedValue);
                    //crReportDocument.SetParameterValue("RPT_YEAR", txtYear.Text);


    crReportDocument.Load(Server.MapPath("~/file.rpt"));

    connectionInfo.DatabaseName="tnsnames_entry";
    connectionInfo.UserID="username";
    connectionInfo.Password="password";
    SetPermissions(connectionInfo);
    crReportDocument.ExportToHttpResponse(ExportFormatType.PortableDocFormat,
                        Response, false, "test01");
    crReportDocument.Close();
                    crReportDocument.Dispose();
                    crReportDocument = null;
    }

    private void SetPermissions(ConnectionInfo conInfo)
            {
                Sections crSections = crReportDocument.ReportDefinition.Sections;
                foreach (Section crSection in crSections)
                {
                    foreach (ReportObject crReportObject in crSection.ReportObjects)
                    {
                        if (crReportObject.Kind == ReportObjectKind.SubreportObject)
                        {
                            SubreportObject crSubReportObject = (SubreportObject)crReportObject;
                            ReportDocument subreport=crSubReportObject
                                .OpenSubreport(crSubReportObject.SubreportName);
                            foreach (CrystalDecisions.CrystalReports.Engine.Table subtbl 
                                in subreport.Database.Tables)
                            {
                                TableLogOnInfo objTableLogonInfo = subtbl.LogOnInfo;
                                objTableLogonInfo.ConnectionInfo=conInfo;
                                subtbl.ApplyLogOnInfo(objTableLogonInfo);
                                subtbl.Location=subtbl.Location.Substring
                                    (subtbl.Location.LastIndexOf(".") +1);

                            }
                        }
                    }
                }
            }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T18:21:29+00:00Added an answer on May 12, 2026 at 6:21 pm

    It turns out that the report we were using was an older Crystal Reports (8 i think) report that was using a .qry file. After we converted the query to a command object (in crystal) everything worked!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am having difficulties getting a subset of results From a huge set of
I am having difficulties getting a span tag to work properly inside a table.
I'm having difficulties getting XslCompiledTransform.Load method to take a server path. I googled around
I'm having some difficulties getting the TabActivity to work. Here's the implementation of the
I getting closer to my goal. But I am having difficulties in disabling the
I'm having some difficulties getting paths within SMP to work right. In the demo
I'm having some difficulties getting my head around inheritance in Ada, and with some
I'm having difficulties getting an association to work with simple_form . I have the
Im having difficulties trying to get a connection to my sqlserver database. The database
I'm having some difficulties getting the PHP libevent extension to break out of a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.