cancel
Showing results for 
Search instead for 
Did you mean: 

Tcode OPK8

Former Member
0 Kudos

I need some type of help/documentation on Tcode OPK8. I want/need to automatically create an iDoc or an output (iDoc is preferred) at the save (creation and change) of a production order (for specific plants). I assume that I can control this in OPK8 but I can't find any information.

Regards,

Davis

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

You can give a print out during saving

In OPK8...Flow control transaction option

for a given plant and transaction you selcet radio button - online...then itb will work. For Idoc you need to define a new output type and give out put with Idoc...you need to set with ABAPer/basis guy to design the new output type with idoc option.

For more details read below

print procedure

Flow control for transactions

You can use flow control to determine for each plant and transaction whether printing is to take place online on updating or in the background. The print mode that you choose here is just a default and can be changed in the actual transaction.

Example

Plant TCode Online Backgr. Update

  • **masked** XXXX **masked** x

Here it is specified that the mode of processing "background printing" is to be proposed in each plant and for all transactions.

come back if required

Edited by: Rajesha Vittal on Jan 21, 2008 7:15 PM

Former Member
0 Kudos

Thanks Rajesha. What I am looking for, in the end, is a way to send an idoc to an external Shopfloor system on the change and creation of certain production orders (based on plant). The way a past programmer solved this issue was to guess the next prod order number in order to create the idoc on the save of the prod order. This worked most of the time but now we are changing the way we create production orders so we are getting duplicate numbers.

Anyway, what I was hoping for was a way to automatically send off an idoc or a way to mark a production order for later (to create the idoc at a later time). The best we could come up with is to append a flag to the production order which would indicate that an idoc has, or has not, been sent. I believe that is what we will use unless there is a standard way to do this in SAP. I would imagine that SAP has taken care of it already but we can't seem to find it.

Regards,

Davis

Former Member
0 Kudos

that is way SAP has user exits...user exit while saving ordres...can be used for your purpose...

Former Member
0 Kudos

I can't get the production order number from any of the user exits because the exit is called before the save (before the number is created). Do you know of a user exit that will give me the production order number?

Regards,

Davis

Former Member
0 Kudos

did you try all user exut with PP*

Edited by: Rajesha Vittal on Jan 22, 2008 6:30 AM

Former Member
0 Kudos

Yes I did, well, I tried all user exits on tcodes CO01 and CO02. I even tried the user exits at the save of the sales order. I was hoping that the sales order saved after the production order was saved (in our flow) but that isn't the case. I believe we will have to resort to appending a field onto AFKO that acts as a flag. We will then use a bit of overlap (based on past production order numbers) and run a batch job that creates idocs and sends them off. I can't believe that SAP doesn't have anything but the closest I can find is a tcode that you run after the production order is saved but this is only tailored to their shop floor system and you must know the production order number. I know what we need isn't unique, there is no way that it can be.

Regards,

Davis

Answers (0)