Page 1 of 1

Emailing from Preview screen

PostPosted: Mon May 17, 2021 11:05 pm
by dtussman
I have a client who likes to email documents from the Preview screen by clicking the @ button at the top. For the last few days when doing that the pdf file that is created by the preview function is cut in half; only the left hand side of the document appears. And it appears larger than normal so perhaps that's why it is cut off. Any ideas what might be happening? Of course when I use the normal print function and select a pdf writer it works fine but she likes doing it her way as it is faster.

Re: Emailing from Preview screen

PostPosted: Tue May 18, 2021 4:06 pm
by Antonio Linares
Could you please post some screenshots ?

What data are you previewing ? How do you generate it ?

Re: Emailing from Preview screen

PostPosted: Tue May 18, 2021 4:35 pm
by dtussman
It happens with any document generated by the program and viewed using the Preview function. My customers do this thousands of times a day with no problem except for this one customer and it just started happening. You know how there is that Factor setting on the Preview screen. Its as though when you click the @ button it also is changing the factor setting to 2. You can even see it enlarge briefly before going to the email screen in Outlook in which the document is displayed with the right half missing and larger than normal as if the factor is set to 2

Re: Emailing from Preview screen

PostPosted: Tue May 18, 2021 4:46 pm
by Antonio Linares
Has he installed a new printer ?

What has changed on his PC lately ?

Re: Emailing from Preview screen

PostPosted: Tue May 18, 2021 5:54 pm
by dtussman
Perhaps. I will check. Maybe a System Restore will resolve it? The one thing she reports is that when previewing something someone clicked on that save as Word document button and the problem began after that.

Re: Emailing from Preview screen

PostPosted: Wed May 19, 2021 12:42 pm
by Rick Lipkin
dtussman

You have two or three ways to create e-mail ..

1) Using Cdo
2) Using SMTP
3) Using the clients Outlook Client

Rick Lipkin

Re: Emailing from Preview screen

PostPosted: Wed May 19, 2021 2:35 pm
by karinha
Test, Please.

Code: Select all  Expand view

// ..\SAMPLES\PRNPDF.PRG

#Include "FiveWin.ch"

STATIC oWnd

FUNCTION Main()

   DEFINE WINDOW oWnd FROM 1, 1 TO 20, 60 TITLE "Printing a PDF"

   @ 3, 3 BUTTON "&Print me" OF oWnd SIZE 80, 20 ;
      ACTION( ( oWnd:Minimize(), PrintMe() ), oWnd:End() )

   ACTIVATE WINDOW oWnd

RETURN NIL

FUNCTION PrintMe()

   LOCAL oPrn AS OBJECT
   LOCAL cError, cSeqErro, nLin, nLinha, oFont

   IF .NOT. FILE( "ERROR.TXT" )

      ? "ERROR.TXT ??"

      BREAK

   ENDIF

   IF FILE( "ERROR.PDF" )

      DELETEFILE( "ERROR.PDF" )

   ENDIF

   BEGIN SEQUENCE

      cSeqErro := MemoRead( "ERROR.TXT" )

      cError := ALLTRIM( cSeqErro )

      PRINTER oPrn NAME "Test PDF" PREVIEW MODAL

      PRINT oPrn PREVIEW FILE "error.pdf"

      DEFINE FONT oFont NAME "COURIER NEW" SIZE 0, -10 OF oPrn

      oPrn:SetPage(9)    // A4
      oPrn:SetPortrait() // Vertical

      PAGE

         nLin := 1

         FOR nLinha = 1 TO MLCOUNT( cError, 100 )

            SYSREFRESH()

            CURSORWAIT()

            oPrn:CmSay( nLin := nLin +.4, 1.5, MEMOLINE( cError, 100, nLinha), oFont )

            IF nLin > 25

               nLin := 1

               ENDPAGE

               PAGE

            ENDIF

         NEXT

         ENDPAGE

         oPrn:lMeta = .T.

      ENDPRINT

      oFont:End()

   END SEQUENCE

RETURN NIL

// FIN / END
 


Regards, saludos.

Re: Emailing from Preview screen

PostPosted: Thu May 20, 2021 6:38 pm
by dtussman
For anyone who might be curious, it was an Adobe problem, solved by reinstalling Adobe Acrobat.