<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Function Module That Creates URL with Picture in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090992#M1358748</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have resolved this by using Knowledge Management functionality&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 20 Sep 2009 15:26:03 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-09-20T15:26:03Z</dc:date>
    <item>
      <title>Function Module That Creates URL with Picture</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090987#M1358743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have looked at old threads but I'm not coming right.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a function module that returns a url with a picture. Obviuosly we would like to say which picture to be loaded. So after executing the function module I would expect it to return a URL.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I take the url and place it in a web browser I would like it to display.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 08:40:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090987#M1358743</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T08:40:19Z</dc:date>
    </item>
    <item>
      <title>Re: Function Module That Creates URL with Picture</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090988#M1358744</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls try get the URL of the Image using FM &lt;STRONG&gt;HR_ESS_WHO_PROG_GET_PICT_URI&lt;/STRONG&gt; .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OR use TCODE OOAD.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If nt clear , pls let me know ...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 08:58:42 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090988#M1358744</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T08:58:42Z</dc:date>
    </item>
    <item>
      <title>Re: Function Module That Creates URL with Picture</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090989#M1358745</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you give some more detail.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What are the import paramaters?? Do you have a sample program??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Does this program tie in with HR?? The pictures will be in a folder on a server.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 09:03:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090989#M1358745</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T09:03:49Z</dc:date>
    </item>
    <item>
      <title>Re: Function Module That Creates URL with Picture</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090990#M1358746</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Exactly this FM is related to HR it is used to display the image of an employee.&lt;/P&gt;&lt;P&gt;U have to just pass the Pernr ( Personnal Number ) from table PA0001.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;U SHALL get the image if it exits in the application server...&lt;/P&gt;&lt;P&gt;if not just load the pic using tcode se78.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if u want a normal image&lt;/P&gt;&lt;P&gt;or try out the following code &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;

REPORT  YH_UPLOAD_EMPLOYEE_PHOTO.

tables: toav0, toaom, twfdb, toapa.

data:
      key        like ojint-key,
      object     like ojint-name,
      object_id  like toav0-object_id,
      archiv_id  like toav0-archiv_id,
      arc_doc_id like toav0-arc_doc_id,
      ablagedatum like sapb-sapabldate,
      ar_date    like toav0-ar_date,
      del_date   like toav0-del_date,
      sap_object like toaom-sap_object,
      ar_object  like toaom-ar_object,
      expiry_tim like toaom-expiry_tim,
      method     like ojint-method,
      return     like ojint-return,
      parameter  like ojint-parameter.

data: begin of i_toav0 occurs 1.
        include structure toav0.
data: end of i_toav0.

data: begin of i_toaom occurs 1.
        include structure toaom.
data: end of i_toaom.

data: begin of fields occurs 1.
        include structure ojfields.
data: end of fields.

data: create(2) value '01'.

data: w_pernr_zero like sapb-sapobjid,
      w_pernr_pass like sapb-sapobjid,
      p_pernr like pa0001-pernr.

data: lw_ar_object like toaom-ar_object,
      lw_object_id like sapb-sapobjid,
      lw_sap_object like toaom-sap_object,
      lw_doc_type  like toadd-doc_type,
      lw_path       like sapb-sappfad.        "toav0-arc_doc_id

data: archiv_doc_id like toav0-arc_doc_id.
data : doc_type like toadt-doc_class.

types:
  begin of types_s_empphoto,
    path  type rlgrap-filename,
    pernr type rp50g-pernr,
  end of types_s_empphoto.

data:
  fs_emp type types_s_empphoto.

data:
  it_emp like standard table of fS_emp.

constants: c_sap_object type toaom-sap_object value 'PREL',
           c_ar_object  type toaom-ar_object  value 'HRICOLFOTO',
           c_doc_type  type toaom-doc_type  value 'JPG'.


CALL FUNCTION 'GUI_UPLOAD'
  EXPORTING
    FILENAME                = 'C:\Documents and Settings\C5131542\Desktop\emp_image1.txt'
    HAS_FIELD_SEPARATOR     = 'X'
  TABLES
    DATA_TAB                = it_emp
  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 &amp;lt;&amp;gt; 0.
* Implement suitable error handling here
ENDIF.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
loop at it_emp into fs_emp.

  w_pernr_zero = fs_emp-pernr.
  clear w_pernr_pass.
  w_pernr_pass = w_pernr_zero.

  select single * from toaom
    where ar_object = c_ar_object
      and sap_object = c_sap_object.

  if sy-subrc eq 0.
    archiv_id = toaom-archiv_id.
    move fs_emp-path to lw_path.
  endif.

  CALL FUNCTION 'ARCHIV_CREATE_FILE'
    EXPORTING
      AR_OBJECT               = c_ar_object
      OBJECT_ID               = w_pernr_pass
      SAP_OBJECT              = c_sap_object
      DOC_TYPE                = c_doc_type
      PATH                    = lw_path
    EXCEPTIONS
      ERROR_CONECTIONTABLE    = 1
      ERROR_PARAMETER         = 2
      ERROR_ARCHIV            = 3
      ERROR_UPLOAD            = 4
      ERROR_KERNEL            = 5
      NO_ENTRY_POSSIBLE       = 6
      ERROR_COMUNICATIONTABLE = 7
      OTHERS                  = 8.

  commit work.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope i am clear...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Ravi Aswani on Sep 11, 2009 11:20 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 09:11:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090990#M1358746</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T09:11:30Z</dc:date>
    </item>
    <item>
      <title>Re: Function Module That Creates URL with Picture</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090991#M1358747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need this to show pictures, teh pictures have nothing to do with HR.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need this to show material pictures, parts, etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can I use this for that also??&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The program shows on my side as one big paragraph.....no gaps, very difficult to read. Is there a way to display it properly if I can use it for my purpose.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would prefer to have all the pics on a folder on the server, then enter the pic I want and returns it like that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 11 Sep 2009 10:02:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090991#M1358747</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-11T10:02:13Z</dc:date>
    </item>
    <item>
      <title>Re: Function Module That Creates URL with Picture</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090992#M1358748</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have resolved this by using Knowledge Management functionality&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 20 Sep 2009 15:26:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/function-module-that-creates-url-with-picture/m-p/6090992#M1358748</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-09-20T15:26:03Z</dc:date>
    </item>
  </channel>
</rss>

