cancel
Showing results for 
Search instead for 
Did you mean: 

Displaying picture stored in ArchiveLink via .NET

Former Member
0 Kudos

Hi guys,

This is my first post. I hope this issue is posted in the right forum. If this has been highlighted before, please point me to the right thread please.

Well here goes. The company I work with is keeping employee pictures (JPEG files) in SAP R3 via ArchiveLink, Tcode:OAAD. The pictures are stored using Business Object: PREL, SAP Object ID: hricolfoto.

I am now required to extract the pictures and somehow display it in a HTML page. I am actually writing an ASP.NET C# web application to display employee's curriculum vitae (CV) using the employee's Master Data stored in SAP.

I found out that the pictures are actually stored in a table named SDOKCONT1.

I am quite confused as to how SAP stores the pictures:

1. It seems that any picture stored will have 2 types of rows in the table. This is assuming that each picture will have a unique PHIO_ID, which I figured is the document ID. One type is with RELID = IN and another is with RELID = IR. For large sized pictures, there will be more rows of with RELID = IR. Does that mean the actual data for the picture are stored in the rows with RELID = IR, while rows with RELID=IN is some sort of header information?

2. How should I proceed to extract the pictures stored in SAP to display in a HTML page. I have written a BAPI which passes the contents of CLUSTD for a specific PHIO_ID. I then attempt to display this as a jpeg but to no avail.

Need some help on this matter. Hope someone can help.

Thanking you guys in advance.

Cheers,

Ming Wei

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Ming Wei,

write an RFC using the function module SCMS_DOC_URL_READ (docID = <docID>, crepID = <crepID>, storCat = SPACE, compID = 'data').

This function module creates a URL that allows the access to the document stored in R/3.

In order to get the right DOCID, CREPID you have to use ARCHIV_GET_CONNECTIONS with SAP_OBJECT = PREL, AR_OBJECT = HRICOLFOTO and OBJECT_ID = <personnel number>.

Best regards

Torsten