cancel
Showing results for 
Search instead for 
Did you mean: 

Access denied. Please check directory setting for files you can access.

Former Member
0 Kudos

Hi ,

I am trying to run this code but i am faceing strange issue with this code that the path is access denied

can you please advice ?

 

RegistryKey key = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\Wow6432Node\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Report Application Server\Server\LocalConnectionMgr");

            if (key != null)

                tempFilePath = key.GetValue("ReportDirectoryPath").ToString();

            if (tempFilePath == "") //set the default

                tempFilePath = @"C:\Program Files\Business Objects\Crystal Reports 12.0\Samples\EN\Reports\";

            tempFilePath += @"NiceReporter\";

            if (!Directory.Exists(TempFilePath))

                Directory.CreateDirectory(TempFilePath);

            tempFilePath += "Evaluators Trend.rpt";

            CrystalDecisions.CrystalReports.Engine.ReportDocument rd = new CrystalDecisions.CrystalReports.Engine.ReportDocument();

            CrystalDecisions.ReportAppServer.ClientDoc.ISCDReportClientDocument boReportClientDocument;

            boReportClientDocument = new CrystalDecisions.ReportAppServer.ClientDoc.ReportClientDocument();

            boReportClientDocument.ReportAppServer = System.Environment.MachineName;

            object path = (object)tempFilePath;

            boReportClientDocument.Open(ref path, 0);

thanks

Fade

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

HI TTT,

Please STOP posting the same question, second time you've done this. 3rd time and you are gone...

See this thread:

Don

Answers (0)