cancel
Showing results for 
Search instead for 
Did you mean: 

CO04N Mass printing issue

former_member700523
Participant
0 Kudos

Hi Experts,

Here there is the problem regarding the mass printing of production orders.

The form used is the Z-form.

Tcode CO04N, I give the selection of multiple orders as 100 to 102 & 105 (4 orders). Other parameters  - On "Mass processing tab" print mode as "Reprint" (as "PRT" is active for all). And Execute Function" with - "Execute Function Immediately" mode.
Then press F8. Then select all the 4 orders & then execute the function of mass processing by pressing mass processing button (in Execute Function Immediately mode). Then from the print pop up window when the print command is given (output device - LOCL, Print immediately check box selected) & the print command is given then then out of the 4 selected orders only one order gets printed (1st copy), when I will repeat my print command then for 2nd & third time then still same order will get printed (copy - 2 & 3). When I will give print command 4 th time then 2nd order will get printed (copy - 1) & so on....

So, the first order will get printed for 3 times after giving command for 3 times. Then I will have to give print command agian for 3 times then 2nd order gets printed for 3 time & then 3rd order (3 commands, 3 copies) & then 4th order (3 commands, 3 copies). In this way this loop will get completed.

I want that with a single print command all 4 order should get printed with copy =1 for each order & this is what normally should happen in mass printing, I beleive.

But this is not happening, but the requirement is that single print command should print all the selected orders & copy = 1.

Can I get some inputs on this what & where I should check ? (From Backgrond mode I get all 4 orders in single command, single spool but 3 copies per order)

Regards,

MHP

Accepted Solutions (1)

Accepted Solutions (1)

svs_sap
Active Contributor
0 Kudos

Hi Manish,

I feel real problem is in your printer setting done by BASIS team. Check in SPAD transaction and you have to give the \n,\f,# no action etc

Check for you Z smart form the settings are in line with standard settings so the identification of next order should be done and print after end of first order.

You can try this if above suggestions has not given full resolution.

Regards,

Sharat

former_member700523
Participant
0 Kudos

Hi All,

Thanks for all the replies here.

The problem of 3 copies seems to be resolved. In OPK8,  the 3 lists (lk01, lg01, lg02) are assined to

the same order type PP01 and to the same z print program. I am using only PP01 order type.

By the change in OPK8 config, now I am getting only 1 copy per order in CO04N,

Now I have still 1 issue -

If there are 3 orders in my selction (all either PRT OR no one is PRT status) then I have to repeat the print command in "Execute Function Immediately" mode, for 3 times. Please refer the following screen.

In the following screen I have to press print button for 3 times that is for no of times which is equal to the number of orders in my selection.

And I guess in CO04N - mass print processing, that with single print command only, I can get the print of all the selected orders.

I know that it is suggested in 2 replies here that the problem is due to "LOCL" as output device & I have to check SPAD & refer to basis.

But Can I get some more information so that I can undersatnd this in better way & can also refer to Basis.

Regards,

MHP

sjeevan
Active Contributor
0 Kudos

I figured the problem of 3 copies was due to maintaining three lists with same form and you made all the three active.

Regarding Print Dialog Box:

That change needs to be done from ABAP programming point of view.

In the print program you pass parameters and options to printer device, there you mention if you want to suppress the dialog box or not. In OPK8, in the print program (open it in SE38) if you scroll you will see ABAP code something like below:

DATA: lv_control TYPE ssfctrlop,

       lv_options TYPE ssfcompop,

CLEAR: lv_control, lv_options.

   lv_control-device    = 'PRINTER'.

   lv_control-no_dialog = 'X'.

   lv_options-tdnoprev  = 'X'.

   lv_options-tddest    = 'LOCL'.

   lv_options-tdnewid   = 'X'.

   lv_options-tdimmed   = 'X'.

The red color line in the above controls the suppression of dialog box. If no_dialog = X, you will not see any dialog box, if no_dialog = ' ' (blank) you will get that dialog box, which in my opinion is very annoying. 

You need to talk with your ABAP developer and tell him to suppress the dialog box for printing. He/she should be able to do it easily.

svs_sap
Active Contributor
0 Kudos

Hi Manish,

In SPAD for printer setting and for the smart form you use (if it is Z) then most of times we forget to assign commands like \n, \f etc which meant to identify next page, etc in printer setting due to which print does not get continued to next page, sometimes print gets overlap etc problem will happen.

I faced it many times when we use Z smart forms assigned with custom print transactions.

Use below option in SPAD and check the setting for your Z form, better to copy standard frorn setting for your Z form to sort out all issues (like copy from X_65_80 to your Z form), using below path

SPAD -> Full Admin -> Device Types  -> SAPWIN -> Formats     -> ZA4 -> End of Page

See the thread for more information for one such example for overlapping issue

http://scn.sap.com/thread/1673042

Best regards,

Sharat

former_member700523
Participant
0 Kudos

Hi,

Thanks for all the replies.

For the specfied Z-progrom in OPK8, in SE38 the code potion mentioned as above looks like as

"no_dialog = X". Please refer the attached code lines below. Not sure if those code lines are same as those are asked for checking.

But if those are same then as "no_dialog = X", the print dialogue window should get supressed. But it is not the case.

Can I get some hints on this ?

   IF cf_retcode = 0.
    MOVE-CORRESPONDING ls_itcpo TO cs_composer_param.
*    cs_composer_param-tdnoprint = 'X'.                    
    cs_control_param-device      = lf_device.
    cs_control_param-no_dialog   = 'X'.
    cs_control_param-preview     = xscreen.
    cs_control_param-getotf      = ls_itcpo-tdgetotf.
    cs_control_param-langu       = nast-spras.

Regards,

MHP

sjeevan
Active Contributor
0 Kudos

That is strange, it should work.

I suggest you to use global search function and search the key word no_dialog. It may have been used somewhere else in the program also.

I think it is not working, maybe because of the following parameter

cs_control_param-preview     = xscreen.

In all the programs I wrote for smartforms it's suppressing the print dialog box. I suggest you to check with your ABAP developer, though.


Check out the threads,

http://scn.sap.com/message/10024468#10024468

http://www.sapfans.com/forums/viewtopic.php?f=13&t=508

http://scn.sap.com/thread/1362490

rupesh_brahmankar3
Active Contributor
0 Kudos

Dear,

Just seat with your ABAPr and debug the same. If standard program and form working fine in that case some issue is with Z-form. So please consult the technical person to sort it out.

Regards,

R.Brahmankar

former_member700523
Participant
0 Kudos

Hi All,

Thanks all.

I got important & valuable information from this thread. I am closing this post with the points given.

Regards,

MHP.

Answers (1)

Answers (1)

rupesh_brahmankar3
Active Contributor
0 Kudos

Dear,

Please refer OSS note 11104

You can also use an additional report (PPPRBSEL), which, like
Transactions CO04 and CO04N, selects the orders to be printedand then prints them. You can also schedule a job for this report (see Customizing). By using this function you could, for example, specify that all orders/networks are to be automatically printed in the evening, provided that they are 'released', but not yet printed (in contract to printing in the background, you do not need to create a print indicator in this case)-> Status selection schema.

Could you please share the screen shot of OPK8 setting?

Regards,

R.Brahmankar

former_member700523
Participant
0 Kudos

Hi,

Thanks for the inputs. I had sheduled this PPPRBSEL in JOB (SM36) with the same orders given as input in prog variant & as expected the same result which is equal to printing by CO04N in background mode. No change. For each order 3 copies are there in spool generated.

But, my question is not on schedulling the job for printing neither on CO04N background printing.

It is on CO04N with mode "Execute Function Immediately" & the problem is decribed completely in my first node.

Can I please get some inputs on that ? If any further information required from my side please let me know.

Regards,

MHP

sjeevan
Active Contributor
0 Kudos

Did you give number of copies to be printed in OPK8 as 3?

former_member700523
Participant
0 Kudos

Hi,

No in OPK8 it is not 3. If needed I can give the snap of screen print.

Any other possibility (I am using Z-form)

Regards,

MHP.

rupesh_brahmankar3
Active Contributor
0 Kudos

Dear,

In OPK8

List control for transaction

ref order type, plant, *

transaction codes *  Have you defined number of prints?

Also in Spool parameters for user active tick mark for Immediate.

Flow control for transactions should be online.

Test the same.

For form/print program if there is anything you need to ask ABAP person to rectify it.


Regards,

R.Brahmankar

sjeevan
Active Contributor
0 Kudos

Z-form shouldn't matter.

I believe it's happening because you gave it as LOCL printer. You need to give a printer which directly prints to the printer, one which doesn't not use the local windows print dialog box. If you use LOCL you have to press OK for each printout it's going to print.

You may find printers in SPAD or talk to your BASIS administrator to give you the device type which doesn't call up windows print dialog box for that printer.

Also remember that LOCL does not work with Background jobs.

I also think you gave the print copies as 3 in your OPK8.

former_member700523
Participant
0 Kudos

Hi All,

Thanks for all the anwers. Attached below is the screen for OPK8.

Please let me know if anything more is needed?

Is there anything which can be there in print program ?

Regards,
MHP

sjeevan
Active Contributor
0 Kudos

The number of printouts in OPK8 is 1, but it's printing 3.

Is it printing 3 copies during CO02 also?

If yes, you need to check the print program.

former_member700523
Participant
0 Kudos

Hi,

Thanks this is very valuable information.

From CO02 when I have given print command & saved the order following is what happened -

In the print pop window appeared I entered "LOCL" as output device "print immediately" check box selected.

Then I have to give print command with selections mentioned as above - 3 times then only that print popup window disappeared.

After that when I checked in SP01 same result 3 copies with 3 different spools. So 3 copies are printed using CO02 as well.

It is suggested above to check te print program & I will do that with the help of ABAP.

But before that I want to know what can be there in print program ?

1) Whether it is possible that in prog 3 copies to be printed is coded ?

2) OR 3 different lists are assigned to same print program & with same Z-form & then program is printing 3 different lists that is 3 times the Z-form. (I am not very much comfortable in config of order printing)

3) OR any other possibility.

Please revert back with inputs so that I may get a proper direction.

Regards,

MHP

sjeevan
Active Contributor
0 Kudos

In OPK8 >> Under Forms >> For the order type, un-check New List.

From CO02 when I have given print command & saved the order following is what happened -

In the print pop window appeared I entered "LOCL" as output device "print immediately" check box selected.

Also, I'm confused about the above statement.

You mean are changing it here (screen-shot below):

and then giving print command and saving?

Manish Phatak wrote:

But before that I want to know what can be there in print program ?

1) Whether it is possible that in prog 3 copies to be printed is coded ?

1. If you're using the standard print program provided by SAP (which doesn't start with a Z or Y ) then it most probably not the problem of print program. If it is a custom Z program, it is supposed to look at field Number of printouts in the above post's screen shot (T496T-DCOPG). Instead in the program they might have hardcoded it to print 3 copies (this is what you need to ask the ABAP programmer to look, it the number of printouts is hard coded or pulling it from some where else or from field T496T-DCOPG).

Manish Phatak wrote:

2) OR 3 different lists are assigned to same print program & with same Z-form & then program is printing 3 different lists that is 3 times the Z-form. (I am not very much comfortable in config of order printing)

2. If this is the case and all the three are active (meaning all are checked), you can verify it in CO02 >> Order >> Settings >> List Control (or) Print Info (above screen shot). Then this is the one causing the problem, because all the three lists have the same print program and same sap-script form . Just put check mark on only one. You can do that in List control for transaction or Spool Parameters for Users. Check and revert back.