Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Closing the PDF application

Hi Everyone,

My requirement is to send a PDF file stored on my desktop for printing and then delete it from my local system. But the trouble is everytime I am opening this PDF document and send it for printing the application remains open and I have to close it manually so that the program can delete it from the system.

My requirement is how can I achieve the above requirement, even if I have to adopt a different approach.Currently I am using the methods mentioned below for opening the PDF,Printing it and then deleting it (in that order ).

CALL METHOD cl_gui_frontend_services=>execute

EXPORTING

document = gv_fname

PARAMETER = lv_parameter

operation = 'OPEN'

***********************************************************

CALL METHOD cl_gui_frontend_services=>execute

EXPORTING

document = gv_fname

PARAMETER = lv_parameter

operation = 'PRINT'

EXCEPTIONS

***********************************************************

CALL METHOD cl_gui_frontend_services=>file_delete

EXPORTING

filename = gv_fname

CHANGING

rc = gv_return

EXCEPTIONS

How can I close the PDF application automatically without user intervention?

Any input is welcome.

Thanks and Regards

Abhishek Kumar

Edited by: abhishek singh on Oct 9, 2008 3:08 PM

Tags:
Not what you were looking for? View more on this topic or Ask a question