2015-02-09 72 views
0

我得到这个错误“文件C:\ Users \ Josephine \ AppData \ Local \ Temp \ Reportlist {BC17FA55-0414-4D23-B78C-311D036ADF6C} .rpt错误:请求不能提交后台处理“。什么似乎是问题? 昏暗的文件作为新的ReportDocumentvb.net导出到磁盘

   Dim ExportPathName As String 
       ExportPathName = String.Concat(New String() {"C:\Exported\", Me.cboList.Text, "\", Me.cboCust.Text}) 
       If Not My.Computer.FileSystem.DirectoryExists(ExportPathName) Then 
        My.Computer.FileSystem.CreateDirectory(ExportPathName) 
       End If 
       'Dim str2 As String = String.Concat(New String() {ExportPathName, "\", Controller.ExportName.ToString, ".pdf"}) 
       Dim str2 As String = String.Concat(New String() {"C:\test.pdf"}) 
       document.Load((Application.StartupPath & "\Reportlist.rpt"), CrystalDecisions.Shared.OpenReportMethod.OpenReportByTempCopy) 
       document.SetDataSource(DS) 
       If System.IO.File.Exists(str2) Then 
        System.IO.File.Delete(str2) 
       End If 
       Me.Cursor = Cursors.WaitCursor 
       ToolStripStatusLabel1.Text = "Exporting to PDF..Please Wait" 
       document.ExportToDisk(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat, str2) 
       document.Dispose() 
+0

它导出为PDF – 2015-02-09 15:01:15

+0

不知道产生错误,如果该文件是相关的:HTTP ://www.sdn.sap.com/irj/boc/go/portal/prtroot/docs/library/uuid/50a6f5e8-8164-2b10-7ca4-b5089df76b33?QuickLink = index&overridelayout = true&36837934524320 – theduck 2015-02-09 16:25:43

+0

尝试写入除了以外的地方启动驱动器的根目录。该应用可能无法访问该应用 – Plutonix 2015-02-09 20:17:40

回答