Skip to Content
-2

Print through Ctrl+P and Print button on standard toolbar

Aug 17, 2017 at 12:32 PM

84

avatar image
Former Member

Hi,

I had requirement where i needed to bypass the print screen and i did that with below code.

CALL METHOD document->print_document

EXPORTING prompt_user = ' '.

BUT when user is giving print by pressing Ctrl+P from keyboard then print screen is prompting and when user is giving print from Print button on standard toolbar then it is not prompting the the print screen.

Any suggestions on what could be done to bypass the print screen for Ctrl+P ?

Thank You.

10 |10000 characters needed characters left characters exceeded

Is your question about the method print_document (of what class?) which always displays a popup to select the printer, and you don't want this popup?

0
Former Member
Sandra Rossi

Hi,

print_document method belongs to interface I_OI_DOCUMENT_PROXY which Prints an Open Document in the Office Application.

There is a parameter prompt_user, if you pass it as empty then it won't give you pop-up window but when you print by pressing Ctrl+P from keyboard then print screen is prompting. When you use print button on the standard toolbar then print screen won't appear.

Thank you.

0

Why don't you give us such information in your question in the first place? Should we roll the dice? Should we guess? How should we know that this question belongs to DMS?

0

In ABAP, you can do your own coding when CTRL+P is pressed : see Horst answer for classical list processing, and for general dynpros put your code in the PAI of the dynpro.

0
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Horst Keller
Aug 17, 2017 at 01:02 PM
1

Are you talking about classical list processing or something else?

In classical list processing, you can set your own list status with SET PF-STATUS, redefine the function code for printing, and implement your own functionality for that function code behind AT USER-COMMAND.

Show 2 Share
10 |10000 characters needed characters left characters exceeded
Former Member

Hi,

Thanks for your response, I am talking about print out of the word document created in DMS. I am printing this document through Zprogram.

For this I can not use PF-STATUS functionality.

Thank You.

0

How did you built your program?
ALV?
SALV?
Just list?

Your scenario is a bit confused.

1