This commit is contained in:
@@ -6382,7 +6382,7 @@ Public Class ClsPaginas
|
|||||||
Dim Archivo As New System.IO.FileInfo(RutaFormato)
|
Dim Archivo As New System.IO.FileInfo(RutaFormato)
|
||||||
If Archivo.Exists Then
|
If Archivo.Exists Then
|
||||||
|
|
||||||
retorno = StreamPDF(RutaFormatoDefault, lrds, params, NombreArchivo, "PDF", MR:=Nothing)
|
retorno = StreamPDF(RutaFormato, lrds, params, NombreArchivo, "PDF", MR:=Nothing)
|
||||||
Dim ArchivoPDF As New System.IO.FileInfo(String.Format("{0}PDF\{1}\{2}.pdf", UsuarioActual.Empresa.Ruta, Vta.TipoDocto, Vta.SerieFolio))
|
Dim ArchivoPDF As New System.IO.FileInfo(String.Format("{0}PDF\{1}\{2}.pdf", UsuarioActual.Empresa.Ruta, Vta.TipoDocto, Vta.SerieFolio))
|
||||||
If Guardar Then
|
If Guardar Then
|
||||||
If Not ArchivoPDF.Exists Then
|
If Not ArchivoPDF.Exists Then
|
||||||
@@ -6406,27 +6406,6 @@ Public Class ClsPaginas
|
|||||||
params.Add(New ReportParameter("Empresa", UsuarioActual.Empresa.Empresa))
|
params.Add(New ReportParameter("Empresa", UsuarioActual.Empresa.Empresa))
|
||||||
params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
|
params.Add(New ReportParameter("RFC", UsuarioActual.Empresa.RFC))
|
||||||
retorno = StreamPDF(RutaFormatoDefault, lrds, params, NombreArchivo, "PDF", MR:=Nothing)
|
retorno = StreamPDF(RutaFormatoDefault, lrds, params, NombreArchivo, "PDF", MR:=Nothing)
|
||||||
|
|
||||||
Dim ArchivoPDF As New System.IO.FileInfo(String.Format("{0}PDF\{1}\{2}.pdf", UsuarioActual.Empresa.Ruta, Vta.TipoDocto, Vta.SerieFolio))
|
|
||||||
|
|
||||||
If Guardar Then
|
|
||||||
If Not ArchivoPDF.Exists Then
|
|
||||||
Try
|
|
||||||
DirectoryExistsCreate(String.Format("{0}PDF", UsuarioActual.Empresa.Ruta))
|
|
||||||
DirectoryExistsCreate(String.Format("{0}PDF\{1}", UsuarioActual.Empresa.Ruta, Vta.TipoDocto))
|
|
||||||
File.WriteAllBytes(String.Format("{0}PDF\{1}\{2}.pdf", UsuarioActual.Empresa.Ruta, Vta.TipoDocto, Vta.SerieFolio), retorno)
|
|
||||||
Catch ex As Exception
|
|
||||||
Alert("Ocurrió un error al generar el PDF", TipoMensaje.MsgAdvertencia)
|
|
||||||
End Try
|
|
||||||
Else
|
|
||||||
Try
|
|
||||||
ArchivoPDF.Delete()
|
|
||||||
File.WriteAllBytes(String.Format("{0}PDF\{1}\{2}.pdf", UsuarioActual.Empresa.Ruta, Vta.TipoDocto, Vta.SerieFolio), retorno)
|
|
||||||
Catch ex As Exception
|
|
||||||
Alert("Ocurrió un error al generar el PDF", TipoMensaje.MsgAdvertencia)
|
|
||||||
End Try
|
|
||||||
End If
|
|
||||||
End If
|
|
||||||
End If
|
End If
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
GuardaLog(String.Format("Ocurrio un error al generar el reporte RLDC {0}", ex))
|
GuardaLog(String.Format("Ocurrio un error al generar el reporte RLDC {0}", ex))
|
||||||
|
|||||||
Reference in New Issue
Block a user