| |
support.activereports2.stdedition
Started by webadmin@datadynamics.com at 08-27-2003 12:00 AM. Topic has 0 replies.
 
 
|
|
Sort Posts:
|
|
|
|
08-27-2003, 12:00 AM
|
webadmin@datadynamics.com
Joined on 12-12-2005
Posts 0
|
Re: Security permissions and .FileName troubles
|
|
|
|
|
Originally Posted By: Rick Blyth<a@a.com>
Hi,
I've compared the code structure in your project to mine and I can't see why mine would behave any differently. Here is my function - I use a property Let to set the m_strFilename variable.
Public Function ExportToByteArray(ByVal objReport As IReport, _ ByVal intExportFormat As ExportFormats) As Variant
On Error GoTo Error_Handler
Dim objPDF As ActiveReportsPDFExport.ARExportPDF Dim objExcel As ActiveReportsExcelExport.ARExportExcel Dim objRTF As ActiveReportsRTFExport.ARExportRTF Dim varByteArray As Variant
objReport.Export With objReport.Report .Printer.DeviceName = "" 'cancel the display of any message boxes with error messages if an error would occur .ShowMessages = False .Run False
If .Pages.Count > 0 Then Select Case intExportFormat Case ExportPDF Set objPDF = New ActiveReportsPDFExport.ARExportPDF objPDF.FileName = m_strFilename objPDF.ExportStream .Pages, varByteArray Case ExportRTF Set objRTF = New ActiveReportsRTFExport.ARExportRTF objRTF.ExportStream .Pages, varByteArray Case ExportExcel Set objExcel = New ActiveReportsExcelExport.ARExportExcel objExcel.ExportStream .Pages, varByteArray End Select End If End With ExportToByteArray = varByteArray Exit Function
Error_Handler: Err.Raise Err.Number, App.Title & "." & m_strClassName & ".ExportToByteArray", Err.Source & ": " & Err.Description End Function
"Trent Snow - DD" wrote in message news:tUdKVi$aDHA.2284@dynaweb.datadynamics.com... > Hello Rick-- > > I tried to reproduce this behavior in the attached project and it seems to > work fine for me. I at first forgot to give my IUSR permission to the Temp > folder but after I did that it worked fine. Can you take a look at the > attached project and let me know if this one works for you? > > "Rick Blyth" wrote in message > news:I67ldI9aDHA.1908@dynaweb.datadynamics.com... > > Hi, > > > > After reading various KB articles I thought i'd found out the problem to > > this but I can't see what i'm doing wrong. > > > > If I pass a filename like "report.pdf" to the DownloadFromByteArray method > > then my report streams down and opens fine. If however, I try and create > the > > temp files anywhere else (eg, pass in "C:\inetpub\wwwroot\test\test.pdf" ) > > then it prompts the user to 'Open or Save' the document. I've got exactly > > the same permissions on my web application folder as I do for the system32 > > folder (both IUSR...... and IWAM...... accounts have read/write access > etc). > > > > Please help me out guys. > > > > TIA > > > > > > >
|
|
|
|
|
Report
|
|
|
|
|
GrapeCity » Forum Archives » support.activer... » Re: Security permissions and .FileName troubles
|
|
|
|
|