- Code: Select all Expand view
#include "Fivewin.ch"
Function Main()
local oWndPdf
local oPdf
DEFINE WINDOW oWndPdf TITLE "Visualizar/Imprimir PDF - Adobe Reader"
oPdf := ShowPdf1( oWndPdf )
ACTIVATE WINDOW oWndPdf VALID ( oPdf:End(), .T. )
Return nil
//----------------------------------------------------------------------------//
FUNCTION ShowPDF1( oWnd )
local oPdf
oPdf := TActiveX():New( oWnd, "AcroPDF.PDF.1" )
oPdf:nTop := 5
oPdf:nLeft := 5
oPdf:nWidth := 500
oWnd:oLeft := oPdf
oPdf:Do( "LoadFile", ".\test.pdf" )
oPdf:Do( "SetCurrentPage", 1 )
oPdf:SetZoom( 75)
RETURN oPdf
Gracias