Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

CV04N -IMAGE DISPLAY IN BSP ?

Hi friends

In cv04n i uploded a image.tif every material no.

By bsp i am giving input material no .

i want to display that image by bsp.

any solution steps

Moosa

Former Member
replied

Hi,

i assume you are comfortable with the document management system.

i assume that you have a doument record with specified:

dokar, doknr, doktl, dokvr (->see table draw).

Now you can do following:

1) Get the files for that record via:

  • Get remote.

call function 'CVAPI_DOC_GETDETAIL'

exporting

pf_dokar = dokar

pf_doknr = doknr

pf_dokvr = dokvr

pf_doktl = doktl

pf_active_files = marked

importing

psx_draw = document

pfx_description = description

tables

pt_files = files

exceptions

not_found = 1

no_auth = 2

error = 3

others = 4.

2) Fetch the right file and fill the object identifier:

object_id-class = 'DMS_PCD1'.

object_id-objid = file-ph_objid.

  • Get remote.

call function 'SDOK_PHIO_GET_URL_FOR_GET_RFC' destination remote_plm

exporting

object_id = object_id

standard_url_only = 'X'

importing

document_url = document_url

tables

urls = urls

exceptions

not_existing = 1

not_authorized = 2

no_content = 3

bad_storage_type = 4

no_urls_available = 5

others = 6.

if sy-subrc = 0.

read table urls into url index 1.

else.

case sy-subrc.

when 1. url-url = 'exception:not_existing'.

when 2. url-url = 'exception:not_authorized'.

when 3. url-url = 'exception:no_content'.

when 4. url-url = 'exception:bad_storage_type'.

when 5. url-url = 'exception:no_urls_available'.

endcase.

endif.

url-url contains a valid url to the file, i.e.picture.

Best regards,

Stefan

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question