FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour Fastreport y PDF sin pasar por un PREVIEW (SOLUCIONADO)
Posts: 1074
Joined: Fri Oct 07, 2005 01:56 PM
Fastreport y PDF sin pasar por un PREVIEW (SOLUCIONADO)
Posted: Wed Mar 06, 2013 09:36 PM

Estimados

hay alguna forma de imprimir una archivo de fastreport a pdf sin pasar por vista preliminar que sea directo, ya que necesito enviar ese archivo por mail
sin que el usuario se entere

desde ya muchas gracias

Saludos
Patricio

__________________________________________________________________
Version: Harbour 3.2.0dev (r1307082134),Compiler: Borland C++ 5.8.2 (32-bit)
PCode version: 0.3, FWH 13.2
http://www.sialm.cl
Posts: 601
Joined: Wed Jul 04, 2007 03:51 PM
Re: Fastreport y PDF sin pasar por un PREVIEW
Posted: Wed Mar 06, 2013 10:07 PM
Hola amigo...
Prueba así:

Code (fw): Select all Collapse
oFr:PrepareReport()
oFr:DOExport("PDFExport")


Espero te sirva.
Saludos, Esteban.
Ojeda Esteban Eduardo.

Buenos Aires - Argentina.

FWH - PellesC - DBF/CDX - ADS - Gloriosos .Bat - MySql - C# .net - FastReport

Skype: jreduojeda
Posts: 2064
Joined: Fri Jan 06, 2006 09:28 PM
Re: Fastreport y PDF sin pasar por un PREVIEW
Posted: Wed Mar 06, 2013 10:13 PM

Haber si esto te ayuda, saludos... :shock:

////////////////////////////////////////////////////////////////////////
// GetProperty()/ Universal functions that set or return any property
// SetProperty() - (except object property) of any Fast Report object.
// Possible values of sObjectName:
//
// Report, Designer,
// PDFExport, HTMLExport, RTFExport, CSVExport,
// XLSExport, DotMatrixExport, BMPExport, JPEGExport,
// TIFFExport, GIFExport, SimpleTextExport, MailExport
//
// For properties of objects that is property of this
// "main" objects '.'-delimeter must be used. For
// example:
// "Designer.DefaultFont"
//
// For full list of values for sPropName param see Fast
// Report documentation:
// http://www.fast-report.com/en/documentation/
//
// Examples:
// SetProperty("Report", "ScriptLanguage", "PascalScript")
// SetProperty("PDFExport", "FileName", "My file.pdf")
// SetProperty("PDFExport", "ShowDialog", .f.)
//
// For Delphi enumerated types and set type use its
// string representation, for example:
// SetProperty("Designer.DefaultFont", "Style", "[fsBold, fsItalic]")
//
////////////////////////////////////////////////////////////////////////

METHOD SetProperty(sObjectName, sPropName, Value) class frReportManager
MEMVAR tmp_Param
PRIVATE tmp_Param := Value
RETURN Call_Func_CC_I(::_SetProperty, sObjectName, sPropName) == 1

Dios no está muerto...



Gracias a mi Dios ante todo!
Posts: 302
Joined: Fri Apr 23, 2010 04:30 AM
Re: Fastreport y PDF sin pasar por un PREVIEW
Posted: Wed Mar 06, 2013 10:34 PM
Para enviar directamente a PDF
Code (fw): Select all Collapse
   cFilenamePdf := "Prueba.pdf"

    oFr:SetProperty("PDFExport", "FileName", cFileNamePdf )
    oFr:SetProperty("PDFExport", "EmbeddedFonts", .t.)
    oFr:SetProperty("PDFExport", "PrintOptimized", .t.)
    oFr:SetProperty("PDFExport", "Creator", "Sistema Uno version 2.0")
    oFr:SetProperty("PDFExport", "OpenAfterExport", .t.)
    oFr:SetProperty("PDFExport", "ShowDialog",.f.)
    oFr:PrepareReport()
    oFr:DoExport("PDFExport")



Slds
Nicanor Martinez M.
Auditoria y Sistemas Ltda.
MicroExpress Ltda.
FW + FWH + XHARBOUR + HARBOUR + PELLES C + XDEVSTUDIO + XEDIT + BCC + VC_X86 + VCC_X64 + MINGW + R&R Reports + FastReport + Tdolphin + ADO + MYSQL + MARIADB + ORACLE
nnicanor@yahoo.com
Posts: 1074
Joined: Fri Oct 07, 2005 01:56 PM
Re: Fastreport y PDF sin pasar por un PREVIEW
Posted: Thu Mar 07, 2013 12:17 PM

Hola

Muchas gracias a todos, funciona perfectamente

Saludos
Patricio

__________________________________________________________________
Version: Harbour 3.2.0dev (r1307082134),Compiler: Borland C++ 5.8.2 (32-bit)
PCode version: 0.3, FWH 13.2
http://www.sialm.cl
Posts: 230
Joined: Thu Sep 17, 2015 11:40 PM
Re: Fastreport y PDF sin pasar por un PREVIEW (SOLUCIONADO)
Posted: Mon Mar 07, 2016 05:05 PM

Saludos,
Algun ejemplo para exportar a Word

Carlos Atuncar - CaSoftSystem
Chincha - Perú
+51983478218
carlosalbatun@gmail.com
Posts: 1074
Joined: Fri Oct 07, 2005 01:56 PM
Re: Fastreport y PDF sin pasar por un PREVIEW (SOLUCIONADO)
Posted: Tue Mar 08, 2016 01:28 PM
Hola

Segun el manual estos son las salidas que soporta, puede que tenga mas ya que tengo una versian antigua

:-)oExport(<cExportObjectName>)
Exports a report using the specified export filter object.
Parameters: <cExportObjectName> - character string containing the name of filter object.
Possible value one of:
"PDFExport", "HTMLExport", "RTFExport", "CSVExport", "XLSExport",
"DotMatrixExport", "BMPExport", "JPEGExport", "TXTExport",
"TIFFExport", "GIFExport", "SimpleTextExport", "MailExport",
"XMLExport", "ODSExport", "ODTExport"
The detailed descriptions of these objects see below.
Saludos
Patricio

__________________________________________________________________
Version: Harbour 3.2.0dev (r1307082134),Compiler: Borland C++ 5.8.2 (32-bit)
PCode version: 0.3, FWH 13.2
http://www.sialm.cl

Continue the discussion