Skip to main content

[archive] Create PDF with File Name Specified

  • May 23, 2006
  • 88 replies
  • 2 views

Show first post

88 replies

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
move spaces to COMMAND-NAME.
INSPECT image-path REPLACING TRAILING SPACES BY "?".
string '"' image-path delimited by "?"
'"' delimited by size
into COMMAND-NAME.
CALL "C$SYSTEM" USING COMMAND-NAME 97.

The above assumes your pdf file (full path name) is in image-path. The image file suffix will dictate which program is used to display the image (jpeg, pdf, etc)

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
move spaces to COMMAND-NAME.
INSPECT image-path REPLACING TRAILING SPACES BY "?".
string '"' image-path delimited by "?"
'"' delimited by size
into COMMAND-NAME.
CALL "C$SYSTEM" USING COMMAND-NAME 97.

The above assumes your pdf file (full path name) is in image-path. The image file suffix will dictate which program is used to display the image (jpeg, pdf, etc)

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
We have also been using the CutePDF product for many years and have been pleased with it. Over the past few years, we've been able to get program updates for 64-bit servers, Windows Vista, etc. They have been good to work with.

Rob

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Mind you that the Adobe Acrobat reader used with Internet Explorer is in fact an ActiveX. Once installed on a machine, you can utilize that to show the pdf inside a window of your application.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Mind you that the Adobe Acrobat reader used with Internet Explorer is in fact an ActiveX. Once installed on a machine, you can utilize that to show the pdf inside a window of your application.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Hi Gisle, any pointers as to where I might look for some decent information on this.
I've been digging around the MSDN and using trusted friend google, but can't find anything appropriate.

An alternative is to use the acu web browser to display the pdf I suppose.


Thanks,

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Hi Gisle, any pointers as to where I might look for some decent information on this.
I've been digging around the MSDN and using trusted friend google, but can't find anything appropriate.

An alternative is to use the acu web browser to display the pdf I suppose.


Thanks,

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
We have viewed the PDF file in several ways:
- open it via the operating system using C$SYSTEM as Keith suggests (will use whatever .pdf opens in, which on my system is Foxit)
- show in a browser window using Acrobat's activex in IE as Gisle suggests
- show it in our own window using the acrobat activex control

All seem to work well for different scenarios.

Rob

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
I used to have an exampley flying around, I will see if I can find it... But it is really straight forward, just use the AxDefGen to generate the definition file (you should find the Acrobat reader component as one of the first ones in the list), then the methods are pretty intuitive by their names.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
I used to have an exampley flying around, I will see if I can find it... But it is really straight forward, just use the AxDefGen to generate the definition file (you should find the Acrobat reader component as one of the first ones in the list), then the methods are pretty intuitive by their names.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Thanks,

Although based on something which Rob mentioned about not using adobe I might avoid the activex control directly.

I've setup a sample here using the acu web browser - this then displays inside a window of our application and also works for a foxit user.

Would there be any advantage of using a call to the op.sys via C$SYSTEM?
I assume that this work in thin client mode using the @DISPLAY syntax

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Thanks,

Although based on something which Rob mentioned about not using adobe I might avoid the activex control directly.

I've setup a sample here using the acu web browser - this then displays inside a window of our application and also works for a foxit user.

Would there be any advantage of using a call to the op.sys via C$SYSTEM?
I assume that this work in thin client mode using the @DISPLAY syntax

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Here is an example of using the Acrobat reader Activex.

       IDENTIFICATION               DIVISION.
       PROGRAM-ID.                  TEMPLATE.
       ENVIRONMENT                  DIVISION.
       CONFIGURATION                SECTION.
       SPECIAL-NAMES.
           COPY "AcroPDF.def".
           .
       FILE-CONTROL.
           SELECT  MYPRINT          ASSIGN TO "-P SPOOLER"
                   ORGANIZATION     IS LINE SEQUENTIAL.
                   
       FILE        SECTION.
       FD  MYPRINT.
       01  PLINE                    PIC X(80).
                   
       WORKING-STORAGE SECTION.
       77  CNTL-FONT                USAGE HANDLE OF FONT SMALL-FONT.
       77  KEY-STATUS               IS SPECIAL-NAMES
           CRT STATUS               PIC 9(4) VALUE 0.
           88  EXIT-PRESSED         VALUE 27.
       SCREEN      SECTION.
       01  TEMPLATE-SCREEN.
    03      MyPDF            AcroPDF
            LINE             1
            COL              1
            SIZE             130
            LINES            40.
           
           03      PUSH-BUTTON
                   LINE             42
                   COL              63
                   SIZE             14
                   TITLE            "E&xit"
                   SELF-ACT
                   EXCEPTION-VALUE  = 27.
       PROCEDURE DIVISION.
       MAIN-LOGIC.
           DISPLAY STANDARD         GRAPHICAL WINDOW
                   TITLE            "Template"
                   CONTROL          FONT CNTL-FONT
                   SIZE             132
                   LINES            45
                   FONT             CNTL-FONT
                   BACKGROUND-LOW.
           DISPLAY TEMPLATE-SCREEN.
           MODIFY  MyPDF            LoadFile("c:\\movies.pdf").
           PERFORM WITH TEST AFTER  UNTIL EXIT-PRESSED
                   ACCEPT           TEMPLATE-SCREEN
           END-PERFORM.
           DESTROY TEMPLATE-SCREEN.
           STOP    RUN.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
This code is based on the output of the Adobe PDF Reader component, found in the Components tab of the Activator.

Want to print it?

MODIFY MyPDF @Print().

or

MODIFY MyPDF @PrintWithDialog().


Have a look in the .def file, lots of possibilities.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
This code is based on the output of the Adobe PDF Reader component, found in the Components tab of the Activator.

Want to print it?

MODIFY MyPDF @Print().

or

MODIFY MyPDF @PrintWithDialog().


Have a look in the .def file, lots of possibilities.

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Thank you Gisle.

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Thank you Gisle.

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
I can't think of an advantage of calling the OS via C$SYSTEM... just another way of doing it... If you did this, then it would be separate from your application, if this was something you wanted...

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
OK,

Tried to investigate calling the OS via C$SYSTEM.
Works perfectly, and probably a better option than the acu web browser.
But I can't get it to work in thin client mode on a unix machine.
Testing with V8.0.0.


           MOVE "C:\\thefile.pdf" TO WS-FILENAME
           MOVE SPACES TO WS-CMD-LINE
           INSPECT WS-FILENAME  REPLACING TRAILING SPACES BY "?".
           STRING   '"'         DELIMITED BY SIZE
                    WS-FILENAME DELIMITED BY "?"
                    '"'         DELIMITED BY SIZE
                 INTO WS-CMD-LINE
           END-STRING                                           

           IF IS-REMOTE
              COMPUTE WS-FLAGS = CSYS-ASYNC CSYS-DESKTOP
              CALL "C$SYSTEM" USING WS-CMD-LINE, WS-FLAGS
                 GIVING WS-STATUS
           ELSE
              COMPUTE WS-FLAGS = CSYS-ASYNC CSYS-HIDDEN CSYS-SHELL
              CALL "C$SYSTEM" USING WS-CMD-LINE, WS-FLAGS
                 GIVING WS-STATUS
           END-IF


Anyone see what I'm doing wrong?

In thin client mode it always returns -1 in the status

Had a search in the forum, but could only see that anytime a problem was encountered the CSYS-DESKTOP flag was missing.

I know another way of achieving this, but I'm just really curious as to why this doesn't work for me.

Thanks,

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
OK,

Tried to investigate calling the OS via C$SYSTEM.
Works perfectly, and probably a better option than the acu web browser.
But I can't get it to work in thin client mode on a unix machine.
Testing with V8.0.0.


           MOVE "C:\\thefile.pdf" TO WS-FILENAME
           MOVE SPACES TO WS-CMD-LINE
           INSPECT WS-FILENAME  REPLACING TRAILING SPACES BY "?".
           STRING   '"'         DELIMITED BY SIZE
                    WS-FILENAME DELIMITED BY "?"
                    '"'         DELIMITED BY SIZE
                 INTO WS-CMD-LINE
           END-STRING                                           

           IF IS-REMOTE
              COMPUTE WS-FLAGS = CSYS-ASYNC CSYS-DESKTOP
              CALL "C$SYSTEM" USING WS-CMD-LINE, WS-FLAGS
                 GIVING WS-STATUS
           ELSE
              COMPUTE WS-FLAGS = CSYS-ASYNC CSYS-HIDDEN CSYS-SHELL
              CALL "C$SYSTEM" USING WS-CMD-LINE, WS-FLAGS
                 GIVING WS-STATUS
           END-IF


Anyone see what I'm doing wrong?

In thin client mode it always returns -1 in the status

Had a search in the forum, but could only see that anytime a problem was encountered the CSYS-DESKTOP flag was missing.

I know another way of achieving this, but I'm just really curious as to why this doesn't work for me.

Thanks,

Shaun

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Depending on the version of Windows (and possibly some other things), I've found that sometimes I need a "start" at the beginning...

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
Depending on the version of Windows (and possibly some other things), I've found that sometimes I need a "start" at the beginning...

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
OK, I'll see.

The windows client is XP Pro 2002 SP2

The Unix machine is running SCO openserver 6

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
i always use 'START'

Dominique Sacre
Forum|alt.badge.img+2

[Migrated content. Thread originally posted on 23 May 2006]

I am able to create a PDF file using "Adobe PDF" as a printer.
However, it automatically goes to the "Save As" dialog when the printer is opened. I want to assign my own file name each time I run the report, then create the PDF, and exit the program. I will then use a system call to view the pdf or attach it to an email it in outlook. I cannot use the temporary file method as I am using win$printer to add a logo and line drawing. I would rather not use active x to create the entire report as that would be too tedious.

Does anyone have a method to accomplish this task? If so, can you also share your code on how you bypass the dialog, and pass the file name. If I cannot bypass the view, I could live with that.

Thanks
Patty
i always use 'START'