Activating Generic Object Services Toolbar in SAP Objects

Abhijeet Kapgate

Posted onNovember 21, 2012 5 minute read

Activating Generic Object Services Toolbar in SAP Objects

FollowRSS feedLike

66 Likes 139,559 Views 88 Comments

Business Requirement

Many a times there is a business requirement of linking documents, entering notes, sending notes or linking an internet address to various SAP objects. These external attachments can be reference documents, pictures, Email attachments, designs, diagrams or related spreadsheets. To meet this requirement SAP has provided a tool bar called ‘Generic Object services toolbar’ or ‘GOS toolbar’.

What is GOS

The GOS is a toolbar that provides different functions such as adding an attachment, creating a document link, displaying all the attachments etc. The attachments are not generic for that transaction but are specific for a particular SAP object. The GOS toolbar can be activated using a class CL_GOS_MANAGER.

Currently in the system the GOS toolbar is available by default only for certain SAP objects.

For Ex. ME21N. See screen shot below. The GOS toolbar is highlighted.

As shown above, the attachments created in ME21N screen will be linked to a particular purchase order and cannot be seen for any other purchase order in ME22N or ME23N screens.

Services that the GOS toolbar provides

The following list shows all possible object services. Not all object services are available – it depends on objects that are already active. Individual object services can also only be accessed using a sub-menu, so that the symbol is not displayed in the toolbox.

Adding an attachment

Entering a Note with an Object

Sending an Object with a Note

Starting a Workflow for an Object

Linking an Internet Address

Entering a Bar Code

Tracing Events for the Object (Subscription)

Telephony

Displaying Object History

Displaying Workflows for the Object

Displaying Transmissions for an Object

Displaying Relationships

Displaying Attachments

Activating Generic Object Services toolbar

The Class CL_GOS_MANAGER is used for activating the GOS toolbar. We have to create an instance of the class. The instance of the class can be created by calling the constructor method. Also, a variable of type BORIDENT needs to be created for the application business object. The object type and object key is assigned to this variable which is then passed to the instance of the class CL_GOS_MANAGER as shown below. This entire code has to be written either inside a suitable user-exit, enhancement point. If both user-exit and enhancement point are not applicable, implicit enhancement can be created inside the standard of that transaction where GOS has to be activated.

The syntax is:

DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,

LS_BORIDENT TYPE BORIDENT.

LS_BORIDENT-OBJTYPE = ‘BUS2081’.

LS_BORIDENT-OBJKEY = ‘12345678902011’.

CREATE OBJECT LR_GOS_MANAGER

EXPORTING

IS_OBJECT = LS_BORIDENT

IP_NO_COMMIT = ‘ ‘

EXCEPTIONS

OBJECT_INVALID = 1.

Here the object key is the combination of the SAP fields that are mandatorily required to execute those transactions. This will publish the GOS with the supplied BO instance if it is used in an executable program.

Earlier the Function Module SWU_OBJECT_PUBLISH was used for activating the GOS toolbar which now has become obsolete. The object type and the object key were passed as the import parameters to the function module.

Example

For the material BOM transactions (CS01, CS02, CS03), the GOS tool bar is not provided by standard SAP. See screen shot below.

We will see below how we can activate the GOS toolbar using above class for transactions CS01 / CS02 / CS03.

To activate it we need to do an enhancement in include ‘LCSDIFCD’ inside form OKCODE_BEARBEITEN. For transaction ‘CS03’ material number, plant, BOM usage are the required fields. See screen shot below:

So the object key for above example is combination of values of material number, plant and BOM usage.

How to get the object key

The object key can be found out from the object type. Enter the object type in transaction ‘SWO1’

Click on display.

E.g. If material number is 100000000000000099,

plant is – 1234 and

BOM usage – 5, the object key will be

Object-key = ‘10000000000000009912345’

2. The object type can be found in table TOBJ and also from transaction SWO1.The object type for Material BOM (CS01/02/03) – BUS1082.

3. Leave the IP_NO_COMMIT parameter as blank.        If the parameter IP_NO_COMMIT is set, it means that your application should start ‘COMMIT WORK’ command. That is also the default value.

If the parameter is empty, the object services will call the ‘COMMIT WORK’. In this case, the data passed should be consistent.

When called because the database changes cannot be reversed using ‘ROLLBACK’.

4. The GOS toolbar / Button will now be visible and activated in t-codes CS01, CS02 and CS03 after the enhancement is activated.

5. For Sales order, the service can be activated by setting user parameter.Set parameter SD_SWU_ACTIVE = ‘X’ in the user profile. This will activate the

generic object services for VA01, VA02 and VA03.

Steps to create attachments for a Material BOM

1] Click on the GOS toolbar. Different options will be displayed.

2.  Click on ‘Create-> Create attachment’ option.

3. A pop-up window will be opened to find a file or attachment as shown below.

Select the file and click on open.

4. A success message will be displayed in the task bar.

5. Now let us create an external document link. Follow the screen shot below:

6. Click on Enter.

A success message will be displayed at the status bar ‘The attachment was successfully created’.

Viewing the attachments

1] To view the list of attachments, go to attachment list as shown below.

2] The list will be displayed as shown below.

Some transactions where GOS is activated using this class.

Alert Moderator

Assigned tags

ABAP Extensibility

abap

activating gos

enhancements

gos

View more...

Related Blog Posts

How to implement GOS for standard transaction VA01/VA02/VA03

By Former Member, Mar 02, 2017

Object still in upgrade mode. Finish the upgrade first

By Former Member, Sep 26, 2016

Part I: Custom Business Object – UI (Bonus Plan)

By Ulrike Liebherr, Jan 20, 2017

Related Questions

Activating Generic Object services for certain SAP objects

By Former Member, Jun 12, 2012

Service for Object button is not available when program is called by RFC

By Marcin Czarny, Sep 07, 2016

Customizing object services toolbar

By Former Member, Aug 26, 2008

88 Comments

Kapil Changrani

November 22, 2012 at 7:36 am

Concise and Informative.

Like(0)

Reply

Alert Moderator

Former Member

November 22, 2012 at 9:33 am

Nice Document....Thanks

Like(0)

Reply

Alert Moderator

Ashutosh Mishra

December 21, 2012 at 11:05 am

Hi,

I am not able to write the code that you provide in above part in enhancement include "LCSDIFCD" for CS01/CS02/CS03.

Please explain me how i will resolve this Issue.

Thanks

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

December 21, 2012 at 11:17 am

Hi Ashutosh,

You will have to create implicit enhancement to write the code.

Like(0)

Reply

Alert Moderator

Ashutosh Mishra

December 21, 2012 at 11:06 am

Helpful answer

Like(0)

Reply

Alert Moderator

Ashutosh Mishra

December 21, 2012 at 1:14 pm

Hi Abhijeet,

Thanks for Quick response!!! can you tell how i ll get the value as a dynamic in Object Key.

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

December 21, 2012 at 1:34 pm

Hi Ashutosh,

If I understand your query correctly, the business object will always be known as to which SAP object needs to be enhanced to have the GOS toolbar and will not be dynamic.For e.g. you will have clear requirement to enhance this particular transaction.Whereas the object key will always be dynamic and its values will be obtained in the standard structures (table,workareas) which get filled run-time inside the includes where you write the code.

Hope this helps.

Thanks.

Like(0)

Reply

Alert Moderator

Ashutosh Mishra

December 21, 2012 at 1:40 pm

Hi Abhijeet,

After doing the Implicit enhancement i did the code in below format then its working for all the material,Plant and BOM Usage.

DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,

IS_BORIDENT TYPE BORIDENT.

data : l_objky(23) type c.

CONCATENATE POMAT-matnr POMARC-werks RC29N-STLAN INTO l_objky.

IS_BORIDENT-OBJTYPE = 'BUS1082'.

IS_BORIDENT-OBJKEY  = l_objky.

CREATE OBJECT LR_GOS_MANAGER

EXPORTING

IS_OBJECT = IS_BORIDENT

IP_NO_COMMIT = ' '

EXCEPTIONS

OBJECT_INVALID = 1.

Thanks a lot for your Document.

Like(0)

Reply

Alert Moderator

Ashutosh Mishra

December 27, 2012 at 10:19 am

Hi all,

If you want to activate Store Business Document then you have to pass the objtype as "BUS1080" in place of "BUS1082" in the above code.

Like(0)

Reply

Alert Moderator

Former Member

June 13, 2013 at 9:26 am

Nice and Informative!.. Good One .Useful.

Like(0)

Reply

Alert Moderator

Aditya Bajoria

July 10, 2013 at 8:23 am

Nice document.

I have a requirement to add this toolbar at budgeting trasnactions such as CJ30-CJ38 etc.

Any help??

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

July 10, 2013 at 11:31 am

Hi Aditya,

Thank you for your query. You can achieve the requirement by following the above post.

If you debug, you will get an include in the PBO for CJ30 where you can add this piece of code thru implicit enhancement.

The include name is - MKBUDF02

Form name - INIT_PROJ_PBO

Click on the 'Enhance' button (Shift + F4). Go to Menu->Edit->Enhancement Operations->Show implicit enhancement options.

A dotted line will appear. Right click->Enhancement implementation->Create

Then write following code:

DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,

LS_BORIDENT TYPE BORIDENT.

LS_BORIDENT-OBJTYPE = 'BUS2001'.

CREATE OBJECT LR_GOS_MANAGER

EXPORTING

IS_OBJECT = LS_BORIDENT

IP_NO_COMMIT = ' '

EXCEPTIONS

OBJECT_INVALID = 1.

Activate the enhancement, executee CJ30 and you will see the GOS toolbar.

Hope this helps. Try this out and let me know if you face any issues.

Regards,

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

Daniil Grishin

June 3, 2019 at 8:48 am

Hello!

We activated GOS for CJ30, but the menu 'Store business document' isn't active.

Although it's active in CJ20N, where I can assign documents to Project Definition (2001) and view.

Any ideas why it's disabled in CJ30?

Like(0)

Reply

Alert Moderator

Former Member

July 20, 2013 at 3:16 am

Hi I am trying to use the GOS for VA41. Currently the service is enabled for VA42 and VA43. But the business requirement is to enable the service for VA41 also. I did get the following docmantation for "Publishing Object and offering the Toolbox Directly" where it talks about using BOR_ID in Create transactions.

As I am new to GOS I still dont where exactly that peice of code should be implemented.

Like above reply could someone help me to let me know where I can implement the GOS for VA41.

Any help is appreciated.

Thanks

HA

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

July 22, 2013 at 7:34 am

Hi Hima,

You can achieve this by doing implicit enhancement in include 'MV45AF0T_TRANSAKTION_INIT' in form 'TRANSAKTION_INIT'.

Pass

LS_BORIDENT-OBJTYPE = 'BUSISM0030'.

LS_BORIDENT-OBJKEY = vbak-auart.

in the above code.

Activate the enhancement and the GOS toolbar will be activated for VA41.

Regards,

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

Former Member

July 22, 2013 at 3:36 pm

Thank you very much for quick reply. It worked lika a charm.

I had one issue though. For customer we have implemented 2 new functionality for GOS. And those are coming in for VA41 also. How do I avoid that.

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

July 23, 2013 at 6:49 am

You can put a if condition for tcode VA41.

Like(0)

Reply

Alert Moderator

Former Member

July 22, 2013 at 10:34 pm

Thank you Abhijeet,

this worked fine.

But the workflow option is grayed out.

How do I enable the Workflow.

THanks

HA

Like(0)

Reply

Alert Moderator

Former Member

July 23, 2013 at 2:26 pm

Hi Abhijeet,

Thank you for your response. I have placed the condition already as I dont want this to be enabled for VA01.

here is my code.

IF sy-tcode = 'VA41'.   DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,         LS_BORIDENT TYPE BORIDENT.

LS_BORIDENT-OBJTYPE = 'BUSISM0030'   LS_BORIDENT-OBJKEY = vbak-auart.

CREATE OBJECT LR_GOS_MANAGER     EXPORTING       IS_OBJECT = LS_BORIDENT       IP_NO_COMMIT = 'X'       IP_NO_INSTANCE = 'X'    EXCEPTIONS       OBJECT_INVALID = 1.

here is my issue. The workflow Icon is activate, but Start workflow, workflow overview, or Archived workflows options are greyed out.

But these options are available in VA42 and VA43 GOS which are standard.

Thanks HA

Like(0)

Reply

Alert Moderator

Former Member

July 25, 2013 at 3:25 pm

Hi Abhijeet,

Any thoughts.

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

July 26, 2013 at 7:05 am

Hi Hima,

The ICON 'Workflow' has three options - Start workflow, workflow overview and Archived workflows.

A]Start workflow - This is used for starting workflows that use the object. All suitable workflows automatically determine the system and are offered for execution.

The SAP System contains active workflows that fulfill the following prerequisites:

1.They must be allowed to start the workflow.

2.The workflow is only allowed to have the object as an obligatory import parameter.

When you click on start workflow - All active workflows which fulfill the prerequisites above are displayed.

B] Display workflow - This will display the overview of the workflow, if any.

C] Archieved workflow - All workflows that are running or have been executed, in which your document (object) has already been edited, are displayed.

So as described above this is standard feature. In my case the behavior of the 'Workflow' button on the GOS toolbar is same for VA41, VA42 and VA43 i.e. workflow Icon is activate, but Start workflow, workflow overview, or Archived workflows options are greyed out.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Former Member

October 24, 2013 at 4:24 pm

Hi,

it is possible to CN28 Transaction??  how is it ??

Regard,

Rafael

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

October 25, 2013 at 10:00 am

The GOS toolbar button is already there for CN28 after you enter values in the first screen.

Like(0)

Reply

Alert Moderator

Former Member

October 25, 2013 at 7:15 pm

Thank Abhijeet for you reply,

in our system SAP ERP 6.06 the GOS button does not appear in CN28 Transaction by standard.

i implemented the solution of this document and it function OK.  but my problem now is the integration between CN28 Transaction and OpenText Throughout SAP ARCHIVELINK.

Like(0)

Reply

Alert Moderator

Former Member

October 29, 2013 at 1:07 pm

Hi Abhijeet (and others too!),

One remark and one question.

The remark :

Despite of what you have written above "5. For Sales order, the service can be activated by setting user parameter.Set parameter SD_SWU_ACTIVE = ‘X’ in the user profile. This will activate the generic object services for VA01, VA02 and VA03." the system is not activated for VA01 but for VA02 and VA03 only. Can you comment?

The question :

Do you know how to achieve in VA01 a simultaneous creation in "Services for Object" of a (default) link to internal network address for sales order on one hand and in Windows of a (default) folder named as "SAP sales odrer number" & "SAP customers name" ?

The business background would then be for sales clerk to populate whenever needed the Windows folder created in such automated way with whatever external document (email, plan, spreadsheet, picture) he needs in order to manage the follow-up of customer order. Thus any person authorized to display customer order (VA03) could check the current status of customer order processing beyond SAP-related matters without systematically disturbing the sales clerk.

Like(0)

Reply

Alert Moderator

Former Member

January 7, 2014 at 6:33 am

Hi Abhijeet(and others too!),

Thanks for all ur valuable suggestions.Iam working out GOS in FMX1 transactions.

IN PBO of the FMX1 we have include 'LFMFRF05(1444)'.Here with implicit enhancement i wrote the below code

DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,

LS_BORIDENT TYPE BORIDENT.

LS_BORIDENT-OBJTYPE = 'FMRE'.

LS_BORIDENT-OBJKEY = 'Z1GOAPINR'.

CREATE OBJECT lr_gos_manager

EXPORTING

is_object        =        LS_BORIDENT

ip_no_commit     =    'X'

The Gos activated successfully and I can able to use create attachement service.But when I click on the Attachment list it is giving dump like below.

TSV_TNEW_PAGE_ALLOC_FAILED.

Thanks In advance,

kranthi

Like(0)

Reply

Alert Moderator

Tanmoy Mondal

January 7, 2014 at 11:58 am

Hi,

I tried to activate the GOS- Generic Object Services for VA01/VA02/VA03 using the user parameter SD_SWU_ACTIVE = ‘X’, but it did not work. Any ideas why?

Regards,

Tanmoy

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

January 14, 2014 at 8:16 am

Hi Tanmoy,

This should work. Probably you will have to log-off after making the changes and log-in again.

The changes should be visible on your next log-in.

If still not, then you will have to contact the basis team.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Craig S

January 7, 2014 at 2:44 pm

Thanks for this document!  Do you know of this process being used to attached documents to a batch?  (I.e. MSC2n?)

Craig

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

January 14, 2014 at 8:17 am

Yes Craig. The same process can be used for your above requirement.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Craig S

January 14, 2014 at 1:03 pm

Thanks Abhijeet and posting this document!

Craig

Like(0)

Reply

Alert Moderator

Former Member

February 28, 2014 at 8:47 am

Hi Abhijeet,

i need to activate GOS for the following tcodes with the business objects listed

1.for CS01, i have used the technique you suggested. its working but the problem is option 'store business object' is inactive 2. how do i make enhancement for QP01 and C201 in the same include(as per your doc)? what must be the object key for both? 3. how do i activate 'store business object' in every transactions?

please do help me

thanks in advance

Like(0)

Reply

Alert Moderator

Dhananjay Choubey

March 13, 2014 at 12:10 pm

Hi,

Nice document. May you please tell me that when i am attaching a file from PC, i want to add a prefix in the filename.

Suppose i am adding a fil with name abc.pdf but it must look like tv_abc.pdf.

you can also reply to this link.

Changing filename of attachment using GOS

Any help will be rewarded.

Thanks.

Dhananjay

Like(0)

Reply

Alert Moderator

Former Member

March 13, 2014 at 3:00 pm

Thanks Abhijeet. Good document.

Like(0)

Reply

Alert Moderator

Former Member

May 6, 2014 at 1:05 pm

Abhijeet,

Great information. How can you notify a user who is displaying the object that an attachment exists? This is needed because a user may not know that an attachment exists. Also how can you require an attachment?

Thanks

Shyam

Like(0)

Reply

Alert Moderator

Pothi Reddy Mahendra Reddy

May 18, 2014 at 8:15 am

Hi Sap Consultants,

This Is Mahendra. How to Activate the GOS Menu  for  these Transactions FMSB/FMSC. Any ideas, Please share the Idea's.

Thanks & Regards,

MahendraReddy.

Like(0)

Reply

Alert Moderator

Pothi Reddy Mahendra Reddy

May 18, 2014 at 8:44 am

Hi Sap Team,

I Created the docuemnt type in oad5 for CRC3 Tranascation. But , Am not able to attach the document. If Error through a Store Business Document is Inactivate Mode. How to re-solve the enable the Store Business document in gos.

Like(0)

Reply

Alert Moderator

Former Member

June 5, 2014 at 11:40 am

Hi Reddy,

You may Try the following,

1. goto SM30

2. maintan the table SGOSATTR

3. select the entry with folowing       Name         : ARL_LINK       Description : Store Business Object

Quick Info   : Store business document

Class         : CL_ARL_SRV_LINK

Icon           : ICON_VIEWER_OPTICAL_ARCHIVE

next           : BARCODE

4. then check the 'commit' check box for the same entry 5. Save

Log off and Log in again and check it

Cheers

Like(1)

Reply

Alert Moderator

Former Member

June 21, 2014 at 5:19 am

Hi Abhijeet Kapgat ,

Very helpful document thank you for sharing knowledge.

Regards ,

Sada Bandla

Like(0)

Reply

Alert Moderator

Damir Karimov

August 5, 2014 at 10:06 am

If object services icon does not appear, there may be the next reasons:

1. User type must be dialog

2. The user parameter must be set up SD_SWU_ACTIVE   =  X

3. The user parameter FLAG_DIALOG_STATUS must not be equal X

Like(0)

Reply

Alert Moderator

Former Member

August 27, 2014 at 2:21 pm

Hi Abhijeet,

my requirement is to add GOS to CS01/CS02/CS03 and CA03/CA02/CA01.

I have gone through your document which is very usefull.Our system is ECC5 System hence there is no scope to create inplicit enhancement spot in the inculde "LCSDIFCD" for CS01 and "LCPDIFH1"for CA01.Can you please suggest how can this be achived in ECC5 system

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

September 3, 2014 at 3:16 pm

Hi Prathamesh,

Sorry for the delayed response.

The only way I could think of is to get the access key to change these includes and write the code accordingly.

Regards,

Abhijeet Kapagte

Like(0)

Reply

Alert Moderator

Former Member

September 10, 2014 at 3:03 pm

Hi Abhijeet ,

Can you kindly confirm if we need to use include LCPDIFH1 and business object 'BUS1012' for activating GOS.

regards,

Prathamesh

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

September 11, 2014 at 12:02 pm

The include is correct but use the business object BUS1082 for CS01/02/03.

Like(0)

Reply

Alert Moderator

Former Member

October 30, 2014 at 8:14 pm

Hi Abhijeet,

Is it possible to attach multiple documents with a single shot?

Regards

Siva

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

November 4, 2014 at 11:22 pm

Hi Siva,

I could not find a way to create multiple attachments in one go, so can't comment on it.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Former Member

November 19, 2014 at 11:22 am

Hi Abhijeet,

For PO ME23N, RFQ ME43 and ME33L Transactions, is there any parameter available like SD_SWU_ACTIVE  for VA03 or do we need to activate the enhancement for purchase related documents.

In document archiving process, we are viewing attachments with the GOS icon "Attachment List"  from a external server and this works fine with the sales documents but "Attachment List"  is inactive in the GOS icon for purchase related documents. Is there any parameter available for Purchase documents.

Thanks

Sudesh

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

November 19, 2014 at 10:24 pm

Hi Sudesh,

The parameter 'SD_SWU_ACTIVE' is only for VA01/02/03. You will need to activate the GOS.

Regarding the 'Attachent List', it should be active if there are any documents.

Regards,

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

Pothi Reddy Mahendra Reddy

November 23, 2014 at 6:46 am

Hi sudesh,

what ever Abhijeet told correct. parameter of SD_SWU_ACTIVE IS ONLY FOR VA01/02/03 T-codes. you need to active the GOS Menu.

Thanks,

Mahendra..

Like(0)

Reply

Alert Moderator

Former Member

March 11, 2015 at 3:20 pm

Hi Abhijeet Kapgate,

It's really a very good document for all those who wants to learn GOS toolbar activation. I was noticed your document while searching for GOS activation process. Seriously it helped a lot. Then my query is that i just want to activate GOS toolbar for MB21/Mb22/Mb23(Material reservation). I am using ECC6.0. Can you guide me which include/coding part would be feasibily to inorder to achieve this? Thank you so much in advance. Eagerly waiting for your response.

With Regards,

Kavi

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

March 12, 2015 at 10:00 am

Hi Kavi,

Glad that the document helped you.

For activating the GOS for material reservation, please use the include MM07RFP0.

Alternatively you can find other includes by debugging, if this include does not serve your purpose. Use the following code in the implicit enhancement:

DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,

LS_BORIDENT TYPE BORIDENT.

LS_BORIDENT-OBJTYPE = 'BUS2093'.

LS_BORIDENT-OBJKEY = RM07M-RSNUM.

CREATE OBJECT LR_GOS_MANAGER

EXPORTING

IS_OBJECT = LS_BORIDENT

IP_NO_COMMIT = ' '

EXCEPTIONS

OBJECT_INVALID = 1.

I tested and it worked. Hope this helps you.

Thank You.

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

Former Member

March 17, 2015 at 4:11 pm

Hi Abhijeet Kapgate,

Thanks for your valuable info  Then i tried out this by inserting those coding into implict enhancement. It can be activated the GOS toolbar. Attachments can be inserted. But there is a new problem that the attachment list is not refreshing properly.

For instance, i have attached one file into one material reservation number say '10001'. Then when i go to mb21 for creating another reservation that old attachment contains for this newly created reservation as well(Instead the attachment list should be empty as its a new creation right?). That is attachment list is not refreshing. It is containing old material number attachment as well. Pls advise whether we need to do code for refresh attachment list if go to Mb21. If yes then how it can be applicable for MB22./MB23. Once again many thanks for your great support

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

March 20, 2015 at 8:57 am

Hi KAVI,

I suppose the attachments are being stored for the transaction and not for particular material reservation. May be you can try to use different include to create implicit enhancement and write the code there.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Ajai J Valiathan

March 20, 2015 at 12:13 pm

Hi Abhijeet,

How do we control the events associated with this toolbar from our own custom program?

For example, I have an alv grid display & as validation, I need to achieve the following:

If I select more than one record in alv & click on this GO toolbar, it should give an error.

To achieve this validation, I need to get the control of this GOS in my program. How can we do it? Please reply.

Thanks in advance,

Ajai

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

March 26, 2015 at 9:04 am

Hi Ajai,

Sorry for the late response. I have not tried this in a custom program, so not sure about this. If you find out, please let us know.

Thanks.

Like(0)

Reply

Alert Moderator

Ajai J Valiathan

March 26, 2015 at 1:46 pm

No problem. Its achieved by using  BADI ‘GOS_SRV_REQUEST’ .

Like(0)

Reply

Alert Moderator

Former Member

March 25, 2015 at 12:56 pm

Hi Abhijeet,

Found the reason for the old attachment repetition in MB21 and MB22. As SAP standard process, we are not supposed to add attachments in creation documents such as VA01, ME21N and MB21 etc. Because all attachments will be stored as binary format in table SRGBTBREL according to object type.

So in my case, even i add attachment in MB21, it will get stored with ID '0000000000' since document number will be created only after it get saved. So that's the reason whenever i go into MB21 freshly i could see the old attachments. Now i have removed it using below selection coding. It's working fine. Thanks for your support.

Select count(*) into lv_count

from SRGBTBREL

where INSTID_A = '0000000000' AND TYPEID_A = 'BUS2093'.

DO lv_count TIMES.

Delete FROM SRGBTBREL where INSTID_A = '0000000000' AND TYPEID_A = 'BUS2093'.

IF sy-subrc <> 0.

EXIT.

ENDIF.

ENDDO.

With Regards,

Kavi

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

March 26, 2015 at 9:06 am

Thanks Kavi for sharing this useful information.

Like(0)

Reply

Alert Moderator

Manohar Dubbaka

July 29, 2015 at 10:34 am

Hi Abhijeet,

Can you please confirm if we have to implement the BADI -- "CL_PLM_AUDIT_GOS" to enable GOS in PLMD_AUDIT transaction?

OR GOS will be enabled by implementing the code mentioned in the blog above in one of the includes of PBO? Also what if there is no business object related to the transaction?

Thanks

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

August 27, 2015 at 4:18 pm

Hi Manohar,

I could find business object for 'Audit' - BUS20350.

Try using it and see. It should work.

Regards,

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

Luis Gabriel Orellana Francisco

August 24, 2015 at 5:56 pm

Hi Abhijeet Kapgate please it's posible VK11, VK12 VK13?

Thanks

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

August 27, 2015 at 4:14 pm

Hello Luis,

You can use the business object BUS3005 for condition type. The key field is ConditionRecordNo. Please try the above approach and see .

You might need to add required attributes and methods to this object.

Regards,

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

deepika jain

August 30, 2018 at 1:44 pm

Hi you can put the enhancement in Include MV130F0F    : FORM FCODE_BEARBEITEN

if sy-tcode = 'VK12' and xvake-knumh is not INITIAL .

DATA: LR_GOS_MANAGER TYPE REF TO CL_GOS_MANAGER,

IS_BORIDENT TYPE BORIDENT.

IS_BORIDENT-OBJTYPE = 'BUS3005'.

IS_BORIDENT-OBJKEY  =  xvake-knumh .

CREATE OBJECT LR_GOS_MANAGER EXPORTING IS_OBJECT = IS_BORIDENT IP_NO_COMMIT = ' ' EXCEPTIONS OBJECT_INVALID = 1.

endif.

Like(0)

Reply

Alert Moderator

Former Member

October 21, 2015 at 9:44 am

Hi Abhijeet n Everyone,

Just wanted to know that in my system i dont get sub option "Create Attachment" in VA02/VA03.

I get only 4 option on clicking create button:

"Create Note"

Create External Document(URL)

Store Business Document

Enter Barcode

but i am not getting the "Create Attachment" option which should allow me upload an excel or word document to Sales order.

Thanks for your help in advance

Regards:

Pranav

Like(0)

Reply

Alert Moderator

Holger Hartung

October 22, 2015 at 6:19 pm

Hello,

i would like use GOS for BUS1191 inspection plan but it dosn't work as expeceted in QP01 - 03.

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

March 1, 2016 at 1:46 pm

Hi Holger,

Sorry for the delayed response. I have used the same business object for inspection plan and the key would comprise of MATNR, WERKS and PLNNR. Hope this helps.

Regards,

Abhijeet Kapgate

Like(0)

Reply

Alert Moderator

Holger Hartung

March 1, 2016 at 1:56 pm

Hi Abhijeet,

no probleme.

Could you please give more details how to run BUS1191 via QP01-QP03?

With CWBQM it already works fine but I would like to run with QP01 to QP03.

Like(0)

Reply

Alert Moderator

Former Member

March 3, 2016 at 5:59 am

Hi Abhijeet,

Its really a very useful document. I am facing a problem in attaching the invoice document to the attachment list in VF02 transaction. I am trying to attach the invoice using an output type(External Send) the document is not getting attached.

Could you please suggest how to attach the invoice document output generated via external send?

Like(0)

Reply

Alert Moderator

Pothi Reddy Mahendra Reddy

March 3, 2016 at 7:57 am

Hi Hemanth,

For Sales order, the service can be activated by setting user parameter.Set parameter SD_SWU_ACTIVE = ‘X’ in the user profile. This will activate the generic object services for VA01, VA02 and VA03 T-codes.

Thanks,

Mahendra Reddy.P

SAP OpenText Consultant.

Like(0)

Reply

Alert Moderator

Former Member

March 3, 2016 at 8:11 am

Hello abhijeet,

Thanku very much for this valueable document. is it possible to insert GOS in transaction like POP1, POP2 and POP3 via enhancement??

Best regards

Arshad

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

April 7, 2016 at 9:01 am

Hi Arshad,

Sorry for the delayed response. Yes, it is possible in transaction POP1, POP2 and POP3.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Atul Tulaskar

May 27, 2016 at 6:36 am

Hi Abhijit,

I would like to activate GOS toolbar for ZBUS2075 and i want to use store business document.

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

May 27, 2016 at 11:34 am

Hi Atul,

GOS toolbar is for the transaction. Which transaction are you referring to?

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Atul Tulaskar

May 31, 2016 at 11:46 am

I am referring to T code KO02. we have created BO ZBUS2075 for a workflow development. so i want to know how can we attach documents against this Z business object.

Like(0)

Reply

Alert Moderator

mohd waliullah

May 30, 2016 at 5:32 am

Hi Abhijit,

I have the same requirement as mentioned above by Atul, I am trying to activate GOS toolbar for EHS&M modules transaction EHSAMBTAET where it does not have any standard Business Object. Here we have created a custom business object and trying to create a document link from SAP to Open text.

Let me know your thoughts.

Thanks,

Wali.

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

May 30, 2016 at 8:44 am

Hi Wali,

So, have you tried the code by passing the business object type and the object key in the class-CL_GOS_MANAGER.

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Uma Surapaneni

June 7, 2016 at 7:01 pm

Hi Abhijeet,

how can we activate this for FV60.

I enhanced the code, but i do not have Object Key while creating Invoice.

Thanks.

Uma

Like(0)

Reply

Alert Moderator

SUBHADIP BOSE

August 1, 2016 at 2:35 pm

Hi Abhijeet,

I am having a similar requirement for IW41 (PM Order Confirmation) transaction. Could you please let me know what would be the business objtect type for the same in order to active the GOS functionality. The F4 help of SWO1 provides a big hit list. Not sure which one to take.

Thanks,

Subhadip

Like(0)

Reply

Alert Moderator

Abhijeet Kapgate Post author

August 5, 2016 at 12:53 pm

Hi Shubhadip,

Sorry for the delayed response. Please try with the following as I am also not sure about the exact one:

BPR_MOCONF

BUS2128

BUS2007

Regards,

Abhijeet

Like(0)

Reply

Alert Moderator

Nitish Chawla

April 24, 2017 at 7:50 am

Hello Abhijeet,

Thanks a lot for such a descriptive document. It helps a lot.

I am working on a custom class based workflow where i need to proide GOS tool bar functionality. Could you please tell me how to utilize custom class instead of Business Object for creating GOS toolbar ?

Regards,

Nitish

Like(0)

Reply

Alert Moderator

jagannath parija

May 3, 2017 at 7:22 am

IS it possible for transaction code PPAMO_CRM  ?

Like(0)

Reply

Alert Moderator

Former Member

October 12, 2017 at 8:36 am

I've implemented GOS in outline agreement and I'm using BOR BUS2014. Insert code into badi name ME_PROCESS_PO_CUST.

The reason why I insert this GOS in ME35K because the approver normally will check the attachments in contract before

approve it. Here the method I used.

Method: IF_EX_ME_PROCESS_PO_CUST~INITIALIZE

DATA: lr_gos_manager TYPE REF TO cl_gos_manager, ls_borident TYPE borident, lv_ekko(15) type c, it_ekko type ekko.

FIELD-SYMBOLS <ekko> TYPE ekko.

IF sy-tcode EQ 'ME33K'.

lv_ekko = '(SAPMM06E)EKKO'. ASSIGN (lv_ekko) TO <ekko>. it_ekko-ebeln = <ekko>-ebeln.

ls_borident-objtype = 'BUS2014'.

ls_borident-objkey = it_ekko-ebeln.

CREATE OBJECT lr_gos_manager EXPORTING is_object = ls_borident ip_no_commit = ' ' EXCEPTIONS object_invalid = 1.

ENDIF.

Like(0)

Reply

Alert Moderator

Vincent PROVENDIER

October 27, 2017 at 9:41 am

Abhijeet Kapgate

in ME21N the GOS toolbar is activated but the store business document id not enable.

do i have to make an Implicit enhancement  some where ?

thanks in advance.

Like(0)

Reply

Alert Moderator

Former Member

April 23, 2018 at 8:39 am

Hi Abhijeet,

I tried the same with ME31L t-code and while creating Schedule Agreement I am attaching one Excel file but when I saw that schedule agreement in ME33L I couldn’t find the attachment.   This is my below code.

IF sy–tcode EQ ‘ME31L’. DATA: lr_gos_manager TYPE REF TO cl_gos_manager, ls_borident TYPE borident, lv_ebeln TYPE ekko–ebeln.

ls_borident–objtype = ‘BUS2013’.

ls_borident–objkey = lv_ebeln.

CREATE OBJECT lr_gos_manager EXPORTING is_object      = ls_borident ip_no_commit   = ” EXCEPTIONS object_invalid = 1.

ENDIF.

Like(0)

Reply

Alert Moderator

Mamatha Karapanahalli

October 4, 2018 at 6:39 am

Hi Abhijeet,

Thanks for the post.

I have a requirement to activate GOS for FB11 transaction. I added the piece of code you have provided in an implicit enhancement. The GOS tool bar appears.

The user wants the workflow overview option. But in my case, GOS is activated and works for only few documents.

For rest of them it throws a message : There are no workflows that have already worked with this object.

Could you please help me with this. Is there a way I can debug GOS and see why no workflow data is being pulled out.

Note: I can see workflow items for this particular document in SWI1.

Thanks.

Mamatha

Like(0)

Reply

Alert Moderator

Peter Atkin

June 19, 2020 at 10:04 am

For CS02/CS03 I did the following:

Added an implicit enhancement in include LCSDIF2B (FORM CUA_SETZEN_U0 )

Added the code below

* Activate GOS for CS02/CS03

data: lr_gos_manager type ref to cl_gos_manager,

ls_borident type borident.

if sy-tcode = 'CS02' or sy-tcode = 'CS03'.

ls_borident-objtype = 'BUS1080'.

concatenate tsd-matnr tsd-werks tsd-stlan into ls_borident-objkey.

create object lr_gos_manager

exporting

is_object = ls_borident

ip_no_commit = ' '

exceptions

object_invalid = 1.

endif.

Like(0)

Reply

Alert Moderator

Pramod Repaka

July 15, 2020 at 4:39 pm

For transaction MSC3N, add implicit enhancement in include LCHRGF02 (End of Form init_screen_data )

DATA: lr_gos_manager TYPE REF TO CL_GOS_MANAGER,

is_borident TYPE BORIDENT.

CONCATENATE dfbatch-matnr dfbatch-charg dfbatch-werks INTO is_borident-OBJKEY.

IS_BORIDENT-OBJTYPE = 'BUS1001002'.

CREATE OBJECT lr_gos_manager

EXPORTING

IS_OBJECT = is_borident

IP_NO_COMMIT = ' '

EXCEPTIONS

OBJECT_INVALID = 1.

Like(0)

Reply

Alert Moderator

PENG ZHANG

December 7, 2020 at 6:34 am

Hello, I would like to ask if you can resubmit for approval after uploading the attachment, such as ME32K, thank you.

Like(0)

Reply

Alert Moderator

Code Desc Object
MIGO GRN BUS2017
ML81N Service Sheet Entry BUS2091
MB1A Goods Issue BUS2017
QA32 Change Inspection lot BUS2045
PA30 HR Master BUS1065
CS01 BOM bus1080
QP01 Inspection Plan BUS1191
C201 Recipe Master BUS1041
MI10 Physical Inventory Posting BUS2028
返回ABAP参考资料列表