Query with links to 'services for object'
Hi everybody
I need your help
We have pictures (jpg, pdf, tif) linked to materials in material master (in transaction mm02 services for object). Sometthing like this - but form materials:
http://www.le.ac.uk/mis/docs/sapdocs/ug/UG5-1%20Services.doc
We would like to create the "stock report" with links to these attachments. Can anyone tell me if it is possible to create these links in the report?
I would like the report to look something like this:
material_number1; stock1; link_to_picture_on_material_number1
material_number2; stock2; link_to_picture_on_material_number2
the user should be able to open the attached picture (if it exists) by clicking the link at each material number (even better if the pictures were already displayed in the report)
Thank you very much in advance
BR,
Jana
There are a number of classes with methods for accessing objects saved using services for object - look for classes starting CL_GOS*
Help for GOS is available at
<a href="http://help.sap.com/saphelp_nw04/helpdata/en/f5/e16f3a53dee246e10000000a11402f/frameset.htm">Generic Object Services (BC-SRV-GBT)</a>
In your report you could link to the relevant code to display the image based on an event like at line selection / at user command or using hotspots or similar in an ALV based report
Andrew
Similar Messages
-
How to get "Services for Object".
Hi,
We are on SAP R/3 4.6C with SAP GUI 6.40.
I don't know much about "Services for Object". In fact, I just noticed the feature.
Some of our user do not see the feature even though they are on SAP R/3 4.6C with SAP GUI 6.40. While others see the feature but not all the time (ex. see in VA22 but not in ME22N)
Is the "Services for Object" some thing individual need to set in the user profile? Or in the SAP GUI or durring SAP GUI installation or is at via roles.
Thanks in advance.
Naing Zaw-TunYou can do it yourself without basis help. Follow the following steps.
From the VA22 go to System -> User Profile -> Own Data
You will reach a new screen. Select the 3rd view "Parameters"
Add one more line with Parameter ID as SD_SWU_ACTIVE and parameter value as "X". Save
Now when you go to any document with VA22. Services for Objects will appear to the left of "CHANGE Quotation xxxxx : OVERVIEW".
Award points if its is helpful -
How to link Employee-Trip with "Services for Object" Attachment.
Hello SAPients.
This is the scenario: I enter the TCode TRIP, enter a personnel number and hit enter, then click on the 'Subsequent Activities' link, then click on the button 'Services for Object', then click on the 'Attachment List' button, I see a list of attachments for the object.
The question is, does anybody knows the table relations to get from 'Employee-Trip' to this attachment list? I know that some of the information I need of the attachment list is stored in table SOOD. But I can't find a way to link from 'Employee-Trip' to the attachment list in SOOD.
Any help will be greatly appreciated <REMOVED BY MODERATOR>
Thanks .
Edited by: Alvaro Tejada Galindo on Jun 9, 2008 3:20 PMStill searching for the answer, any idea?
Thanks! -
Services for object linked note to DMS DIR
dear sir,
we have created DIRs(cvo1n) and attached notes using Services For Object. The notes is visible in attachement list.Now we want to generate a report in which these notes should be available against respective DIRs.
we created a query using SQVI, linking tables DRAW,DRAT,TDWST,TSOTT and SOOD.
But this will show all the notes available in that language ( no link with DIRs)
we want to have the Notes which are attached to respective DIRs in report.
it may be possible if we link the table contains DIR and SOOD link table,which we don't know
can you suggest some method to get the details of Notes available in Services For Objects?
thanking you
srinivas paii am closing this thread
-
Services for Object - Store Business Documents (issue with XLSX files)
Hi,
We are using the Services for Object > Store Business Document to be able to drag and drop files into (for example) Sales Inquiry, Sales Order, Sales Quotations etc.
Within OAC2 we have set up the global document types and these have been linked to the relevant Object Types and Content Repositories in OAC3. We have also set up the Content Repository as Document Area 'ARCHLINK'.
The ArhciveLink Basic Settings in OAG1 have the 'Always Copy Document Class from Document Type' set under Storage Settings.
The issue we are having is with XLSX document types. When we drag and drop the XLSX documen type using the Store Business Document the file is stored against the Sales Order but when you come to view the attachments MS Excel opens but an error message appears saying 'Excel cannot open the file '******' because the file format or file extension is not valid. Verify that the file has not been corrupted and that the file extension matches the format of the file'?
We have reviewed SAP notes 1925897, 1739026 and 1145885 however non appear to give me a clear answer as to why this is happening?
I have found that if we unselect the option 'Always Copy Document Class from Document Type' in OAG1 then we can open the XLSX files.
As we have a significant amount of documents attached to various objects, what would be the implications of making this change agianst existing records and new records?
Any advice on this issue would be greatly appreciated.
Gary BHi David,
No joy I'm afraid!!
I added entry 'xlslx' with the relevant MIME Type, Application and Description into table TOADD for the ArchiveLink settings and also this entry was already in tables SDOKMIME and SDOKFEXT for KPro.
I then following the process via the Services for Object within VA12 (Change Inquiry) to then Create > Store Business document > Select the relevant Document Type > Drag and Drop the XLSX file into the empty box.
I then saved the record and tried to view the attachement but I am still getting the same message 'Excel cannot open the file '******' because the file format or file extension is not valid. Verify that the file has not been corrupted and that the file extension matches the format of the file'?
Our client is on componet SAP_BASIS release 701 Support Level 0014 and Support Package SAPKB70114 and I can see that note 1237688 is for SAPKB70112?
Regards
Gary -
Attachments with services for object in ME42 along with RFQ via 'ME9A' .
Hello Guys,
I have a MM requirement where the user attaches some document in ME42 via services for object functionality to a particular RFQ. Here the user wants to attach this document during sending of mail with ME9A to the vendor.
As by SAP standards we are only able to send RFQ in PDF format to vendors.
Thanks in advance
RegardsHi,
You can attach an attachment to RFQ IN ME9Avia E-mail. Communication strategy need to define in CS01. E-mail address need to maintain in vendor master record. Codition records need to maintain in NACE or IN mn04. Use sap note 191470. This is for PO, the same can be used for RFQ. Please refer below link for step by step assistance. Thanking you.
RFQ send by mail through SAP server -
Retrieval of attachments with services for object in ME22n or ME23n
Hello experts,
I have a MM requirement where the user attaches some document in ME22n or ME23n via services for object functionality to a particular PO. Here the user wants to attach this document during sending of mail with ME9F to the vendor. First of all is it possible with the standard functionality of ME9F? or Requires some Zdevelopment. Anyone can guide me how to extract the attachment and send it with mail, does it require some configuration from functional side? I searched the forums but did not find the ways to extract.
Thanks in advance
Regards
Raj (SAP ABAP)Hi Raj,
Did you find a way to extract the attachment? -
Services for Object in Maintenance order can not link
Hello,
"Services for object" in Maintenance Order can not link to share point.
Linking documents from the C drive or Global drive is successful but if SHAREPOINT is used, it fails
When trying to link to a Word document on our Sharepoint... It fails... when I'm in an order... it gives me an error... (displayed on the attached Word file...) and when I'm working within a document... (CVN02) it merely links to my C:\ drive which won't work...
We need to link to our "master" Sharepoint (web based) documents.
Please suggest the solution.
Thanks
Regards
AnilAnil,
Couldn't you add the web address as the attachment?
Regards
Narasimhan -
Services for Object: attached documents/ links cannot be deleted
Dear SAPfriends,
The deletion button at the attachment list of "Services for Object" does not work. Eventhough it seems that the documents/ links/ notes have been removed from the object (i.e. Purchase order, material etc), when you exit and re-enter at the attachment list the documents are still there.
I tried to delete them from OAER, still the same.
Any ideas?
Yr help will be very valuable.
Kind Regards,
Elly LeondiHello Mauro,
Thanks for yr reply.
That was the problem.
Thanks again.
Regards,
Elly -
My workflow is not listed in the GOS (Services for object)
Hello Experts,
I developed a workflow and linked the BO ZBUS2081. This is sub type of standard BO BUS2081. I am using the custom event INVOICEBLOCKED to trigger the workflow. The workflow is triggered propely when the invoce is created (with block) thru MIRO and I can see the workflow in SWEL or SWI6 or SWI14.
But, the workflow is not listed in the services for objects button of the invoice display using MIR4.
If I use the standard event 'BLOCKEDQUANT' as starting event, the workflow is triggered and I can view it in services for object.
In the table SWW_WI2OBJ has all entries about the workflow triggered using standard event or custom event.
How can I make the services for object in invoice list my workflow that was triggered using custom evet?
Appreciate your help.
Regards
Siva SHi Siva
Thanks for marking this thread answered.....We are glad that your issue was solved :-) ....... But I do agree with Rick Bakker, the first correct answer was by Paul Bakker and I had just elaborated on that.
Please mark the first correct answer as the "green" one.
Regards,
Modak -
Content server for Document attachment through "services for object" Icon.
Guys,
I have typical problem in installation of Content server for storing external documents.
We all know that we can attach the document in SAP using the icon SERVICES FOR OBJECT. By this we can attach the document to the specific object we want.
-Since my client wants only document attachment method not to completely implement SAP DMS, I proposed this method of attaching documents through services for object method.
-If documents are stored though services for object ,The attached document will directly get stored in sap database(correct me if I am wrong) while in DMS it ask you to select the storage location while u check in for any document
-By storing the doc thru "services for object " For long run when we store the documents in sap database our system will drastically get slow down.
-In this regard I have a plan to incorporate external storage server.
-Now I should know that how I should customize content server configuration so that the attachment through services for object will store into this content server I need to know how to define Client, Content Category, Content Repository, Document Area, Physical Machine, IP Address, Port. (OACT & OAC0)
I appreciate for immediate solution and <u><b>Points will be rewarded for sure.</b></u>
Regards,
Murali.SHi Murali,
Don't Worry, its possible,
All attachments can be stored in SAP Content Server also, but through archiving process.
Set up a database storage system.
Preparation
Make sure that the HTTP plugin is active.
Transaction <b>SMICM,</b> "Display Services" function key (shift F1)). The list of services must contain a port other than 0 for HTTP.If not, you must adjust the relevant profile parameter.
<u>Typical entry:</u>
icm/server_port_0 PROT=HTTP, PORT=1080, TIMEOUT=900
<b>Make sure that the /sap/bc/contentserver service is active.</b>
If no user is defined, then use transaction SU01 to create a new user. Use the "System" user type.Assign
the SAP_ALL and SAP_NEW profiles to the user. (Eg: HRUSER/PLMUSER/PPUSER etc)
Transaction <b>SICF,</b> select: default_host - sap - bc -contentserver. Select the function to display/change the service. Make sure that a user is defined.
Using the relevant data from the newly created user, maintain the anonymous logon data for the
/default_host/sap/bc/ service and save & activate the changes in transaction <b>SICF</b>. Double click on content server and give the user name which has been created (HRUSER/PLMUSER/PPUSER/MMUSER etc)
Check the system PSE.
Start transaction <b>STRUST</b>. Expand the system PSE. The system PSE must be "green" for each application
server.
Determine a suitable exchange directory.
The exchange directory must be accessible from each application server. If all application servers are running on the same platform (for example, Windows), one network directory that is accessible on all application server (for example,
server\share) is sufficient. You can generally use the global directory
(profile parameter DIR_GLOBAL).You can use the RSPARAM report to determine the profile parameters.
Setting up the storage
Create a table for storing the data. Using transaction <b>SE11</b>, create a copy of the SDOKCONT1
table. If you want to create the repository database, you can name the table ZCONT_DB, for example. Save the
table as a local object. Activate the table.
Create a repository.
Use transaction <b>OAC0</b> to create a new repository.
Use the following parameters:
Repository Max. two characters, for example, Z1
DocArea: ARCHLINK
Storage type: R/3 database
Storage subtype: normal
Version no. : 0046
Contents table <table name> for example: ZCONT_DB
Exchange directory <directory name> for example:
server\share\
Make sure that the exchange list ends with a \ (or /on Unix).If you are using a variety of platforms, you must use transaction FILE to define a suitable logical file name and use this name. Save the settings.
1. Maintain view table <b>TOAAR_C</b>, via SM31
Cross client table displayed as information, forget it
2. In field 'StSytm' you must entered 'Z1' as your system need, or anything that you need but you must configure HR Archive link too.
3. In field 'Arch.path' (direct above Spoolpath), entered path in your system, this real path in your operating system. May be you should confirm to your Basis consultant where exactly you could store picture files. So if you enter '/', your file exists at root directory at your UNIX system.
4. Choose 'File store' radio button
5. Save.
First
<b>1. You have to create a number range for SAP ArchiveLink.
IMG: Basis Components-> Basis Services -> SAP ArchiveLink -> Basic Settings-> Maintain number ranges
(Trxn <b>OANR).</b> Create number range 01 from 0000000001 to 9999999999 without the external number flag.
2. Document type <b>HRICOLFOTO</b> must exist with document class JPG.
IMG: Basis Components->Basis Services->SAP ArchiveLink->System Settings->Maintain document types
(Table<b> TOAVE, Trxn OAC2).</b>
3. Document type <b>HRICOLFOTO</b> must be linked to object type PREL and Infotype PA0002.
IMG: Personnel Management->Personnel Administration->Tools->Optical archiving->Set up Optical Archiving
in HR. (View V_T585O, no Trxn). In the first two columns there are minuses, the third (Date) has
a plus - don't put a flag in the check box.
4. Check which content repository (Archive) is linked to document type HRICOLFOTO and object type
PREL. IMG: <b>Basis Components->Basis Services->SAP ArchiveLink->Basic Settings->Maintain Links (Table
TOAOM_C, Trxn).</b></b>
Test
Test the repository.
Use transaction SE38 to start the RSCMSTH0 report. Specify your repository (i.e. Z1) and start the test.
The report must run without errors. If no problems occurred, you can use the new repository with Archive Link after you carry out the Archive Link Customizing. If problems do occur, check whether one of the related
notes helps.
For More Details :
http://service.sap.com/archivelink.
<u><b>
NOTE:- Screen Shots are missing, i was not able to paste here, One more thing is we did this for uploading a PHOTOS into Content Server, Similarly you have to create a REPOSITORY and Z-TABLE to bring all the Attachments from all the selected Objects and then route them to the CONTENT REPOSITORY.</b></u>
Your Senior ABAP guy would help you in this, if not i may try to help you more by monday.
Regards
Rehman
<b>Reward Your Points if Satisfied.</b> -
Services for Object (GOS) Attachement List not showing after attachment
Hi All,
I have created a new entry for the Generic Object Service List and this links to a copy of the CL_GOS_SRV_ATTACHMENT_CREATE class (Create attachment) with some additional logic. However, after attaching a file, the "Attachment List" does not become available until after I re-enter the transaction. The attachment list is showing the correct attachments.
After some (understatement...) investigation, I found that even if I try and link the new service to a unchanged copy of the CL_GOS_SRV_ATTACHMENT_CREATE service in SGOSATTR, it is not working. It is attaching fine, but the "Attachment List" entry in the Services for Object Menu is still greyed out. If I attach the original class CL_GOS_SRV_ATTACHMENT_CREATE to the newly created entry it works fine. e.g. straight after I attach a file to the transaction, the menu entry becomes available.
I can't find where the re-draw of the GOS menu happens and hence can not determine what is going wrong. Does anybody know if this is part of the Kernel or is this actually done in ABAP ?
Am I missing something ? Debugging including system debugging for two days now and can't find it... very frustrating.
Any help would be appreciated.
Thanks,
Wouter.Hi Wouter,
I had originally posted to ask if you had resolved this since I was facing the same issue, but then deleted my post when I was able to get it working. Sorry, I didn't mean to initiate a flurry of activity in such an old thread.
My scenario is I created a new GOS service entry in table SGOSATTR using transaction SGOSM. My new service uploads attachments to an external document management system via a call to a RESTful web service. The class I use in the SGOSM entry is a custom subclass of CL_GOS_SRV_URL_CREATE.
I resolved this issue by taking a look at what CL_GOS_SRV_URL_CREATE does in its EXECUTE method. The key bits to refresh the GOS Attachment List with the new attachment are...
raise event commit_required. " if SGOSM has the commit flag checked
raise event service_succeeded
exporting eo_service = me.
These events tell any subscribers to go do their thing-- which in this case includes a refresh of the GOS Attachment List. So in the EXECUTE method of my custom subclass, after I call function BINARY_RELATION_CREATE, I raise these events...
CALL FUNCTION 'BINARY_RELATION_CREATE'
EXPORTING
obj_rolea = gs_object
obj_roleb = rel_doc
relationtype = 'URL'
EXCEPTIONS
OTHERS = 1.
CASE sy-subrc.
WHEN 0.
MESSAGE s043(sgos_msg). " The attachment was successfully created
RAISE EVENT commit_required.
RAISE EVENT service_succeeded
EXPORTING eo_service = me.
WHEN OTHERS.
MESSAGE s042(sgos_msg). " The attachment has not been created
ENDCASE.
I hope this is helpful to you even though your initial implementation was a while back. Thanks for replying to my question though!!
Cheers,
Amy -
Attachments to Notifications - using "Services for Object"
Hi All,
I have sucessfully created a VC application (7.0 sp13) to create a General Notification in R/3
using the BAPI - IQS4_CREATE_NOTIFICATION
Our users in R/3 4.7 use the button in the Top Left Hand corner of the Screen "Services for Object"
to attach MS Word documents to Notifcations. Using the Create Attachment option from the Services for Object toolbar that pops up when the button is clicked.
Has anyone else tried this or have any advice on how this can be done in VC - if you can recommend a BAPI that I can try or will this be a custom ABAP BAPI.
Thanks in advance for any advice you can offer.
- RobertFUNCTION z_pm_attachment_and_url.
*"*"Interface local:
*" IMPORTING
*" VALUE(I_QMNUM) TYPE QMNUM OPTIONAL
*" VALUE(I_AUFNR) TYPE AUFNR OPTIONAL
*" VALUE(I_URL) TYPE SO_URL OPTIONAL
*" VALUE(I_FILE) TYPE ZPMCT002 OPTIONAL
*" VALUE(I_FILENAME) TYPE STRING OPTIONAL
*" TABLES
*" T_RETURN STRUCTURE BAPIRET2
* Objetos locais
DATA:
vl_url TYPE so_url,
vl_path TYPE string, "#EC NEEDED
vl_loopc TYPE sy-loopc,
vl_lines TYPE sy-loopc,
vl_filename TYPE string,
vl_filelength TYPE i,
it_url TYPE STANDARD TABLE OF sood-objdes,
it_obj_cont TYPE STANDARD TABLE OF solix,
wa_obj TYPE borident,
wa_obj_cont TYPE soli,
wa_obj_data TYPE sood1,
wa_folder_id TYPE soodk,
wa_document_id TYPE sofmk.
DEFINE valida_retorno.
loop at t_return into t_return.
if t_return-type eq zgtpm_e.
exit.
endif.
endloop.
if t_return-type eq zgtpm_e.
exit.
endif.
END-OF-DEFINITION.
* === Valida parâmetros de entrada
IF i_qmnum IS INITIAL AND i_aufnr IS INITIAL.
* Nenhum objeto informado: Informe Nota ou Ordem de Manutenção
PERFORM mensagem_retorno_tab
USING
'ZPM_PORTAL' zgtpm_e '055' '' '' '' ''
CHANGING
t_return[].
EXIT.
ELSEIF NOT i_qmnum IS INITIAL AND NOT i_aufnr IS INITIAL.
* Informe apenas um objeto: Nota ou Ordem de Manutenção
PERFORM mensagem_retorno_tab
USING
'ZPM_PORTAL' zgtpm_e '054' '' '' '' ''
CHANGING
t_return[].
EXIT.
ENDIF.
IF i_url IS INITIAL
AND i_filename IS INITIAL.
* Informe Anexo e/ou URL
PERFORM mensagem_retorno_tab
USING
'ZPM_PORTAL' zgtpm_e '060' '' '' '' ''
CHANGING
t_return[].
EXIT.
ENDIF.
* === Define Categoria de objeto
IF NOT i_qmnum IS INITIAL.
wa_obj-objkey = i_qmnum.
wa_obj-objtype = 'BUS2038'. " Nota PM
ENDIF.
IF NOT i_aufnr IS INITIAL.
wa_obj-objkey = i_aufnr.
wa_obj-objtype = 'BUS2007'. " Ordem de manutenção
ENDIF.
* === Anexo
IF NOT i_filename IS INITIAL.
* Conteúdo do arquivo
IF NOT i_file[] IS INITIAL.
it_obj_cont[] = i_file[].
DESCRIBE TABLE it_obj_cont LINES vl_lines.
READ TABLE it_obj_cont INTO wa_obj_cont INDEX vl_lines.
vl_filelength =
( 255 * ( vl_lines - 1 ) ) + STRLEN( wa_obj_cont ).
ELSE.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = i_filename
filetype = 'BIN'
IMPORTING
filelength = vl_filelength
TABLES
data_tab = it_obj_cont
EXCEPTIONS
file_open_error = 1
file_read_error = 2
no_batch = 3
gui_refuse_filetransfer = 4
invalid_type = 5
no_authority = 6
unknown_error = 7
bad_data_format = 8
header_not_allowed = 9
separator_not_allowed = 10
header_too_long = 11
unknown_dp_error = 12
access_denied = 13
dp_out_of_memory = 14
disk_full = 15
dp_timeout = 16
OTHERS = 17.
IF sy-subrc <> 0.
PERFORM mensagem_retorno_tab
USING
sy-msgid sy-msgty sy-msgno sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
CHANGING
t_return[].
EXIT.
ENDIF.
ENDIF.
* Pasta de Destino
PERFORM get_folder CHANGING wa_folder_id t_return[].
valida_retorno.
* SAPoffice: definição do objeto, modificar atributos
wa_obj_data-objla = sy-langu. " Idioma
wa_obj_data-objsns = 'O'. " Objeto confidencial
wa_obj_data-objlen = vl_filelength. " Tamanho conteúdo documento
wa_obj_data-ownnam = sy-uname. " Nome proprietário
CALL METHOD cl_report_viewer=>split_path_filename
EXPORTING
i_filename = i_filename
IMPORTING
e_path = vl_path
e_filename = vl_filename.
SPLIT vl_filename AT '.' INTO
wa_obj_data-objdes " Descrição breve do conteúdo
wa_obj_data-file_ext. " Extensão de file de uma aplicação PC
CONDENSE wa_obj_data-file_ext NO-GAPS.
* Insere Objeto (Anexo)
PERFORM object_insert
USING
'EXT' " Anexo
wa_obj_data
wa_folder_id
it_obj_cont
CHANGING
wa_document_id
t_return[].
valida_retorno.
* Relacionamento Objeto PM x Anexo
PERFORM relation_create
USING
'ATTA'
wa_obj
wa_document_id
CHANGING
t_return[].
valida_retorno.
ENDIF.
* === URL
IF NOT i_url IS INITIAL.
* Inicializa estruturas comuns a Anexo e URL
CLEAR:
it_obj_cont,
wa_obj_cont,
wa_obj_data,
wa_folder_id,
wa_document_id.
* Conteúdo da URL
MOVE i_url TO vl_url.
WHILE NOT vl_url IS INITIAL.
CONCATENATE '&KEY&' vl_url(250) INTO wa_obj_cont.
APPEND wa_obj_cont TO it_obj_cont.
SHIFT vl_url LEFT BY 250 PLACES.
ENDWHILE.
* Pasta de Destino
PERFORM get_folder CHANGING wa_folder_id t_return[].
valida_retorno.
* SAPoffice: definição do objeto, modificar atributos
wa_obj_data-objla = sy-langu. " Idioma
wa_obj_data-objsns = 'O'. " Objeto confidencial
wa_obj_data-ownnam = sy-uname. " Nome proprietário
SPLIT i_url AT '/' INTO TABLE it_url.
DESCRIBE TABLE it_url LINES vl_loopc.
READ TABLE it_url INDEX vl_loopc
INTO wa_obj_data-objdes. " Descrição breve do conteúdo
* Insere Objeto (URL)
PERFORM object_insert
USING
'URL' " Link Inter/Intranet
wa_obj_data
wa_folder_id
it_obj_cont
CHANGING
wa_document_id
t_return[].
valida_retorno.
* Relacionamento Objeto PM x URL
PERFORM relation_create
USING
'URL'
wa_obj
wa_document_id
CHANGING
t_return[].
valida_retorno.
ENDIF.
* === Libera objetos locais
FREE:
vl_url,
vl_path,
vl_loopc,
vl_lines,
vl_filename,
vl_filelength,
it_url,
it_obj_cont,
wa_obj,
wa_obj_cont,
wa_obj_data,
wa_folder_id,
wa_document_id.
ENDFUNCTION.
***INCLUDE LZGPM0010F01 .
*& Form mensagem_retorno_tab
FORM mensagem_retorno_tab
USING
p_msgid TYPE symsgid
p_msgty TYPE symsgty
p_msgno TYPE symsgno
p_msgv1 TYPE any
p_msgv2 TYPE any
p_msgv3 TYPE any
p_msgv4 TYPE any
CHANGING
t_return TYPE ty_return.
DATA:
vl_msgty TYPE symsgty,
wa_return LIKE LINE OF t_return.
IF p_msgty IS INITIAL.
MOVE zgtpm_e TO vl_msgty.
ELSE.
MOVE p_msgty TO vl_msgty.
ENDIF.
IF p_msgno IS INITIAL.
EXIT.
ENDIF.
MOVE p_msgid TO wa_return-id.
MOVE vl_msgty TO wa_return-type.
MOVE p_msgno TO wa_return-number.
MOVE p_msgv1 TO wa_return-message_v1.
MOVE p_msgv2 TO wa_return-message_v2.
MOVE p_msgv3 TO wa_return-message_v3.
MOVE p_msgv4 TO wa_return-message_v4.
MESSAGE ID p_msgid TYPE vl_msgty NUMBER p_msgno
WITH p_msgv1 p_msgv2 p_msgv3 p_msgv4
INTO wa_return-message.
APPEND wa_return TO t_return.
FREE: vl_msgty, wa_return.
ENDFORM. " mensagem_retorno_tab
*& Form get_folder
FORM get_folder
CHANGING
w_folder_id TYPE soodk
t_return TYPE ty_return.
CALL FUNCTION 'SO_FOLDER_ROOT_ID_GET'
EXPORTING
region = 'B' " ?
IMPORTING
folder_id = w_folder_id
EXCEPTIONS
OTHERS = 1.
IF sy-subrc <> 0.
PERFORM mensagem_retorno_tab
USING
sy-msgid sy-msgty sy-msgno sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
CHANGING
t_return[].
ENDIF.
ENDFORM. " get_folder
*& Form object_insert
FORM object_insert USING
p_objtp TYPE so_obj_tp
w_obj_data TYPE sood1
w_folder_id TYPE soodk
t_obj_cont TYPE zpmct002
CHANGING
w_document_id TYPE sofmk
t_return TYPE ty_return.
* Objetos locais
DATA:
it_objcont TYPE STANDARD TABLE OF soli,
it_obj_head TYPE STANDARD TABLE OF soli,
wa_obj_id TYPE soodk,
wa_obj_cont LIKE LINE OF t_obj_cont.
* RAW to CHAR
LOOP AT t_obj_cont INTO wa_obj_cont.
APPEND wa_obj_cont TO it_objcont.
CLEAR wa_obj_cont.
ENDLOOP.
* Insere objeto
CALL FUNCTION 'SO_OBJECT_INSERT'
EXPORTING
folder_id = w_folder_id
object_type = p_objtp
object_hd_change = w_obj_data
owner = sy-uname
IMPORTING
object_id = wa_obj_id
TABLES
objhead = it_obj_head
objcont = it_objcont
EXCEPTIONS
active_user_not_exist = 1
communication_failure = 2
component_not_available = 3
dl_name_exist = 4
folder_not_exist = 5
folder_no_authorization = 6
object_type_not_exist = 7
operation_no_authorization = 8
owner_not_exist = 9
parameter_error = 10
substitute_not_active = 11
substitute_not_defined = 12
system_failure = 13
x_error = 14
OTHERS = 15.
IF sy-subrc = 0.
w_document_id-foltp = w_folder_id-objtp.
w_document_id-folyr = w_folder_id-objyr.
w_document_id-folno = w_folder_id-objno.
w_document_id-doctp = wa_obj_id-objtp.
w_document_id-docyr = wa_obj_id-objyr.
w_document_id-docno = wa_obj_id-objno.
ELSE.
PERFORM mensagem_retorno_tab
USING
sy-msgid sy-msgty sy-msgno sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
CHANGING
t_return[].
ENDIF.
* Libera objetos locais
FREE:it_objcont, it_obj_head, wa_obj_id, wa_obj_cont.
ENDFORM. " object_insert
*& Form relation_create
FORM relation_create
USING
p_relationtype TYPE binreltyp
w_obj TYPE borident
w_document_id TYPE sofmk
CHANGING
t_return TYPE ty_return.
DATA wa_doc TYPE borident.
wa_doc-objtype = 'MESSAGE'.
CASE p_relationtype.
WHEN 'ATTA'.
wa_doc-objkey = w_document_id(34).
WHEN 'URL'.
wa_doc-objkey = w_document_id.
WHEN OTHERS.
ENDCASE.
CALL FUNCTION 'BINARY_RELATION_CREATE'
EXPORTING
obj_rolea = w_obj
obj_roleb = wa_doc
relationtype = p_relationtype
EXCEPTIONS
no_model = 1
internal_error = 2
unknown = 3
OTHERS = 4.
IF sy-subrc = 0.
COMMIT WORK AND WAIT.
CASE p_relationtype.
WHEN 'ATTA'.
* O anexo foi criado com êxito
PERFORM mensagem_retorno_tab
USING
'SGOS_MSG' zgtpm_s '043' '' '' '' ''
CHANGING
t_return[].
WHEN 'URL'.
* A URL foi criada com êxito
PERFORM mensagem_retorno_tab
USING
'ZPM_PORTAL' zgtpm_s '059' '' '' '' ''
CHANGING
t_return[].
WHEN OTHERS.
ENDCASE.
ELSE.
PERFORM mensagem_retorno_tab
USING
sy-msgid sy-msgty sy-msgno sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
CHANGING
t_return[].
ENDIF.
FREE wa_doc.
ENDFORM. " relation_create
Edited by: Fabrício Alves Vieira on Apr 8, 2008 3:08 PM -
Hi,
When I am enclosing some document or file in services for object in sap in me23n, how can I know that some object is attached without seeing the attachement list. Secondly if anyone want to delete the attachement he can delete, we want that the person who has attached the attachment should delete the attachement not anyother person. How to achive this.
Regards
IshuHi, There is no standard report or transaction to get this other than looking at the object through the transaction that creates those attachments, also you can go through SAP OSS note 530792
Refer below link for creating a report for your requirement
http://it.toolbox.com/wiki/index.php/GOS_Finding_Attachments_or_Links_to_an_Object_in_SAP/ABAP
For second requirement it can be handled by Authorization, discuss with your basis guys -
Services for Object ECC 6.0
Hello,
I'm executing QM02 for quality notification. It is desired to send the quality complaint and other documents via email. There is a services for object
icon that allows the emailing to external mail. however when the document
is received, it only contains what appears to be header text: BOR BUS2078
and the notification number. How can I get the document as an attachment using the services for object?Hi Ricky
When you use services & Send function for any object, you will receive a SAP inbox email with a link to the corresponding object. When you click on that link, system takes you to the object (in your case Quality Notification).
BOR BUS2078 is the link for quality notification.
If you try to send the service to an external mail, you may not receive the link as hence you will see only BOR text.
If you want to send a notification as email to an external address:
follow menu Notification->Print->Notification.
Select the Print Preview option ; Then download as a PC file into your PC. Then send email with your email program.
Best regards
Ramki
Maybe you are looking for
-
Sale Order / Project specific Inspection Plan
Dear All, I want to create Sale order or Project specific inspection plan for a material. This is because, my customers want some specific inspection requirements for individual materials, which are assigned to Sale order or project. I want to inspe
-
Screen/Desktop Only showing one program at a time...
My mom called me in to look at her iMac earlier today. She said she was moving her illustrator window off to the side when all of the sudden it was "sucked" away to the left side of the screen. Now when she tries to bring up more than one window for
-
Encapsulation vs. performance
We are creating a J2EE application with an O-R mapper to solve the persistence problems. We plan to create Java objects which encapsulate certain aspects by creating a service interface. These services use persistent objects backed by some database t
-
I have done searches for this before but never found anything. I used to have an All in wonder series video card but I did not like the price jump to get a newer card so I decided after much research to go with the TV Wonder Pro but there is one thin
-
Obtaining x.509 certificate or DN
From within an EJB method, how do you obtain the certificate or DN from the client cert used to establish a mutually authenticated connection to the EJB? The goal of this is that we have a mutually authenticated connection between the EJB caller and