Unable to display employee image in pdf forms from webdynpro?

hi friends,
i am using webdynpro application and ADOBE forms. i designed adobe form with 3 fields. IM_VORNA, IM_NACHN, IM_PHOTO.
I created one interface of adobe form also with the 3 fields of which specified above.
And i am using webdynpro application to get the details of emplyee by passing pernr.
i created a view. in this, and i attached every thing interface context. And in methos tab, wddoinit method i wrote code like this...
DATA pernrid TYPE PERNR-PERNR.  "tdobname.
  DATA temp TYPE c.
  DATA: p_connect_info TYPE TOAV0,
        wa_p_connect_info TYPE TOAV0,
        p_document_type TYPE TOAV0-RESERVE,
        exists TYPE c.
  DATA: url TYPE char255,
        turl TYPE string,
        turl1 TYPE xstring.
  DATA lo_nd_z_if_test_cv TYPE REF TO if_wd_context_node.
  DATA lo_el_z_if_test_cv TYPE REF TO if_wd_context_element.
  DATA ls_z_if_test_cv TYPE wd_this->element_z_if_test_cv.
* navigate from <CONTEXT> to <Z_IF_TEST_CV> via lead selection
  lo_nd_z_if_test_cv = wd_context->get_child_node( name = wd_this->wdctx_z_if_test_cv ).
* get element via lead selection
  lo_el_z_if_test_cv = lo_nd_z_if_test_cv->get_element(  ).
* get all declared attributes
  lo_el_z_if_test_cv->get_static_attributes(
    IMPORTING
      static_attributes = ls_z_if_test_cv ).
* *** Vorna and Nachn.
ls_z_if_test_cv-im_vorna = 'shankar'.
ls_z_if_test_cv-im_nachn = 'chamala'.
***pernr
  pernrid = '00000003'.
CALL FUNCTION 'HR_IMAGE_EXISTS'
  EXPORTING
    P_PERNR                     = PERNRID
*   P_TCLAS                     = 'A'
*   P_BEGDA                     = '18000101'
*   P_ENDDA                     = '99991231'
IMPORTING
   P_EXISTS                    = exists
   P_CONNECT_INFO              = P_CONNECT_INFO
EXCEPTIONS
   ERROR_CONNECTIONTABLE       = 1
   OTHERS                      = 2
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
P_DOCUMENT_TYPE = P_CONNECT_INFO-RESERVE.
CALL FUNCTION 'SCMS_DOC_URL_READ'
  EXPORTING
*   MANDT                      = SY-MANDT
    STOR_CAT                   = SPACE
    CREP_ID                    = P_CONNECT_INFO-ARCHIV_ID
    DOC_ID                     = P_CONNECT_INFO-ARC_DOC_ID
*   PHIO_ID                    =
   COMP_ID                    = 'DATA'
*   SIGNATURE                  = 'X'
*   SECURITY                   = ' '
*   USE_LOCATION               = 'A'
*   LOCATION                   = ' '
*   HTTP_URL_ONLY              = ' '
   DP_URL_ONLY                = 'X'
*   LIFETIME                   = ' '
*   NO_CACHE                   = ' '
*   EXPIRATION                 =
*   PDF_MODE                   = ' '
*   URL_EXTENTION              = ' '
*   FORCE_GET                  = ' '
IMPORTING
   URL                        = URL
EXCEPTIONS
   ERROR_CONFIG               = 1
   ERROR_PARAMETER            = 2
   ERROR_SIGNATURE            = 3
   HTTP_NOT_SUPPORTED         = 4
   DOCGET_NOT_SUPPORTED       = 5
   NOT_ACCESSABLE             = 6
   DATA_PROVIDER_ERROR        = 7
   TREE_NOT_SUPPORTED         = 8
   NOT_SUPPORTED              = 9
   OTHERS                     = 10
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
turl = url.
CALL FUNCTION 'HR_KR_STRING_TO_XSTRING'
  EXPORTING
*   CODEPAGE_TO            = '8500'
    UNICODE_STRING         = turl
*   OUT_LEN                =
IMPORTING
   XSTRING_STREAM         = turl1
EXCEPTIONS
   INVALID_CODEPAGE       = 1
   INVALID_STRING         = 2
   OTHERS                 = 3
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ls_z_if_test_cv-im_photo = turl1.
*** Get the Photographs 
*CALL METHOD cl_ssf_xsf_utilities=>get_bds_graphic_as_bmp
*  EXPORTING
*    p_object       = 'GRAPHICS'
*    p_name         = pernrid
*    p_id           = 'BMAP'
*    p_btype        = 'BCOL'
*  receiving
*    p_bmp          = ls_z_if_test_cv-im_photo
*  EXCEPTIONS
*    not_found      = 1
*    internal_error = 2
*    others         = 3
*IF sy-subrc EQ 0.
**  MOVE 'y' TO temp.
** MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
**            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
*ENDIF.
*** Send the values back to the node
  lo_el_z_if_test_cv->set_static_attributes(
    EXPORTING
      static_attributes = ls_z_if_test_cv ).
But here the problem is when i executed this application i am able to see the VORNA and NACHN fields in ADOBE Form. But the employee photo is not appearing in adobe form.
Here employee photo i amretreving from archive link.
Even i set the Imagefield property URL in Adobe forms.  i.e $record.IM_PHOTO.
Any solutions regarding this...
Regards,
Shankar.

Hi Shankar,
according to the sap documentation (inserting a graphic), I could imagine the following problems
1.) image file type is not supported (-> "see the online help in Adobe LiveCycle Designer under Defining Object Properties ® Image Fields ® About Image Fields" )
when you use "Graphic Reference"
2.) url could not be accessed.(-> "This means that you may have to configure appropriate access rights for Adobe Document Services (ADS)" ).
Maybe this will help you finding the problem.
Regards,
Andreas

Similar Messages

  • Problems in displaying an Image in PDF Form

    hi,
    I have to display a photo in the PDF form dynamically, hence i have a used an element of type <b>Image Field</b>, where the URL has to be passed to fetch the photo from the location. though all the bindings has been done, the photo is not displayed. please help me find the solution.
    Thanks and Regards
    Poojith M V

    Hi Poojith ,
    follow these steps;
    -Choose imagefield element on to adobe form
    -Right click select choose image ,Browse for the image from the local drive.
    -Select Ember image Data
    -Select Add to library ,save it
    Now drag the added image from library on to adobe form and use.
    Cheers
    Swathi
    Do offer pts;-)

  • How to display employee photo in pdf through WebDynpro OR ABAP print Progr?

    hi,
    I have uploaded employee photos using TCODE OAOH. Now all the employee photos are stored in Archive link.
    Now my requirement is i have get the employee photo and display it in PDF using PDF forms and  webdynpro OR using ABAP print program.
    I am able to get the employee photo from SAP archive link using ABAP code. After this i have to upload this to MIME reository. From MIME repository i have to display it in PDF forms from WEbDynpro.
    I tried with ABAP print program, directly calling the PDF form in program and display the employee data with Employee Photo. With my program i am able to see only employee data. But it's not displaying employee Photo.
    Plz any helps to display employee photo in PDF forms using either webdynpro OR ABAP printprogram.
    If ur reply is related to WebDynpro, pla tel me how to upload photo to MIME repository From Archive Link.
    Since all the employee photos are uploaded into Archive link using Tcode OAOH. From this i have to get the employee photo and upload it to MIME repository and i have to display it in PDF forms.
    Any help are appreciated.......
    Regards,
    Shankar.

    Hi Sankar,
    1)You can use the program BSP_UPDATE_MIMEREPOS to upload the photos in the mime repository.
    2)Use the following code to get the content from your mime and set the content to your interactive UI element as Xstring format.
        data:
        mime_repository type ref to if_mr_api,
        content type xstring,
        url type string value '/SAP/BC/BSP/SAP/myBSPapplication/rajkumar.jpg'  .
      mime_repository = cl_mime_repository_api=>get_api( ).
      call method mime_repository->get
        exporting
          i_url     = url
        importing
          e_content = content.
      wd_context->set_attribute( name = 'DATAS' value = content ).
    Thanks,
    Rajkumar.S

  • Messenger Express 6 Unable to display embedded images

    Hi
    Messenger Expresss seems tob unable to display embedded images (gif or jpeg) in the form cid:image.gif and some hosted images. In reference to the the cid:image.gif , when I open the email get an error from the browser that states "Warning: the application cid must be lauched to view this file." or something close to that. It gives me a choice of opening "cid" or canceling. There is also a check box "remember my choice for all files." which I choose and then I get an email full of broken image links.
    I've tried this in Firefox and IE the routine is a bit different but the result is the same. No images displayed.
    I also used a netflix email I recieved.. some of the images displayed some did not. The ones that did display were from www.netflix.com some of the others hosted on an image server somewhere in the netflix namespace did not.
    I'm at a loss. If anyone can shed some light on this I'd be very thankful
    Erik

    I was speaking about what client created the original mail messate.
    The "error message" isn't very useful. Is the mail message itself is badly formed, then the problem lies with the client that created it.
    You should be able to tell from the headers of the message.
    If you have the message file on disk, examine it with a text editor. "Message file on disk" means the original file, as stored on the server as a xxx.msg file, not what any client might save to a local disk.
    When we work these kinds of things as tech support cases, we start out with this file.
    I have no idea what gmail does, so that's not really relevant.
    Your IMAP client may be better at displaying badly formed messages than webmail is.

  • How to Display an Image on my FORM

    Good Day!
    I would like to ask some help from you guys with my problem on how to display an image on my form. I would like to display my uploaded image on my form but instead of an image, the get_blob_file is showing. By the way, I'm using Apex 4.1
    I downloaded the Order Entry Sample Application and followed the Page 6, the Product Details. I even made snapshots of each details from Page Rendering to Page Processing in order not to miss a thing.
    At the moment, I was able to upload or store the image on my created Oracle table and also able to retrieve it on the Download Link Text with Content Disposition value of Inline, provided by APEX Settings. If I invoke the Download link beside the file browser, a page with the image will be shown, below is the address:
    http://127.0.0.1:8080/apex/apex_util.get_blob_file?a=200&s=339877802936975&p=230&d=7107921433296839&i=7107601420296838&p_pk1=54&p_pk2=&p_ck=7D6512D967336C4B94258EEA3CDF1BE6&p_content_disposition=inline
    However, instead of showing the image on a region, below is the one showing on my Form:
    <img src="apex_util.get_blob_file?a=200&s=339877802936975&p=230&d=7107921433296839&i=7107601420296838&p_pk1=54&p_pk2=&p_ck=7D6512D967336C4B94258EEA3CDF1BE6" />
    As you can see the parameter values are the same but I know I missed something that's why I'm here :)
    I would highly appreciate all the help you can provide and many thanks in advance.
    I tried to change gear by making an html region of type PL/SQL (anonymous block) and a procedure but still no image :(
    Below are the scripts.
    declare
    cursor cur is
    select *
    from wsemployee
    where empid = :P230_EMPID;
    begin
    for rec in cur
    loop
    IF rec.mime_type is not null or rec.mime_type != '' THEN
    htp.p( '<img src="my_image_display?p_image_id='||NVL(rec.empid,0)||'" height="'||100||'"/>' );
    else
    htp.p( 'No Image ');
    END IF;
    htp.p( ' ');
    end loop;
    end;
    PROCEDURE
    create or replace PROCEDURE my_image_display( p_image_id IN NUMBER)
    AS
    l_mime VARCHAR2 (255);
    l_length NUMBER;
    l_file_name VARCHAR2 (2000);
    lob_loc BLOB;
    BEGIN
    SELECT MIME_TYPE, PHOTO_BLOB_CONTENT, PHOTO_FILENAME,DBMS_LOB.GETLENGTH(photo_blob_content)
    INTO l_mime,lob_loc,l_file_name,l_length
    FROM wsemployee
    WHERE empid = p_image_id;
    -- set up HTTP header
    -- use an NVL around the mime type and
    -- if it is a null set it to application/octect
    -- application/octect may launch a download window from windows
    owa_util.mime_header( nvl(l_mime,'application/octet'), FALSE );
    -- set the size so the browser knows how much to download
    htp.p('Content-length: ' || l_length);
    -- the filename will be used by the browser if the users does a save as
    htp.p('Content-Disposition: attachment; filename="'||replace(replace(substr(l_file_name,instr(l_file_name,'/')+1),chr(10),null),chr(13),null)|| '"');
    -- close the headers
    owa_util.http_header_close;
    -- download the BLOB
    wpg_docload.download_file( Lob_loc );
    END my_image_display;
    Edited by: user13831927 on Dec 22, 2012 3:24 PM

    Hi Ying,
    you can add a UDF to the table spp2 with a programm
    but the table is not yet listed in the 'Manage User Fields' form.
    there's no way to "enable" it - sorry

  • Displaying an image in a form

    hi,
    i am trying to display an image in a form. The code worked fine in j2me emulator, but when i converted the program to a jar and ran the same program in my mobile phone.
    i get an exception in Image.createImage(.. method
    and exception value is just null.
    i know the image is not found in the specified location. but the image is there in the jar file.
    how do i solve this issue?
    thanks in advance.

    Its definitly the heap size image, it can be case that image size is very large, u just try by optimizing the image and decreasing the size of image,
    or
    the image size(widht*height) is larger than actual phone screen
    try with small image(small width*height) you will come to know the problem
    @rjun

  • Create pdf form from image file

    is there any way to create a pdf form from an image?  perhaps using ghostscript?  TIA

    #pacman -S potrace
    The only disadvantage of this utility is input image format is bmp only.

  • Sending Data to PDF Forms from ABAP Program.

    Hi Experts,
    I left ABAP Programing for a while around 1+ years Due to some personal problems
    Now I have struck up with new issue. Its ADOBE PDF forms.
    I am Entirely new to this topic & knows about Nothing.
    My requirement is to display a report in PDF form. Its totally Independent form from NACE.
    I have written a Driver program & retrieved all the DATA into a Final internal table.
    Now All that I need is to display the same Internal Table data into PDF form output.
    Can anyone help me how to send this data(47 records in Internal table with 8 fields in Internal table) to PDF.
    Please help me out Experts with any suggestions.
    Thanks & Regards,
    Dileep .C

    Hi,
    if u pass your internal table to smartform we can achieve . because we can convert smartform output into pdf easily.
    Regards,
    karthikeyan k s,
    Edited by: karthikeyanks on Nov 19, 2010 12:58 PM

  • Dynamically populating a dropdown list in a pdf form from a datasource

    Is there a way to populate a dropdown list in a pdf form from a datasource, specifically from an Access database table or query, using LiveCycle Designer. I am easily able to do this using cfselect in Coldfusion, however, cannot seem to figure it out for pdf forms. I am aware of the Show Dynamic Properties option enabled in LiveCycle Designer, and then binding to a datasource. However, this seems limited as I am only able to select single columns from Access (currently using an Access database) tables, and a unable to select from queries like I do using cfselect in Coldfusion forms. Is this something that must be done with Java scripting? If so, is there any other way? I know nothing about scripting. Thanks

    Derrick,
    There is a sample posted at
    http://www.adobe.com/devnet/livecycle/articles/lc_designer_db_lookup_tip.pdf
    It was created for Designer 7.0 but it should function the same in later versions of Designer.
    Steve

  • PDFMaker missing files issue with PDF Forms from Office 2007

    Hi,
    I have Adobe PDF 8.0 Pro installed  (full installation) and I upgraded office from 2003 to 2007 AND Windows from 2000 to XP Pro.
    I used to be able to create PDF Forms from an Excel document when using Office 2003.
    Now, when I choose to create a new form starting with an electronic document [from an Excel 2003 document (.xls)], I get this error message:
    "PDFMaker files are missing, would you like to repair?" (please image attached)
    I did the repair. Did not worked.
    I made sure the add-in in office was enabled. Did not worked.
    I un-installed Adobe 8.0 Pro and Adobe Reader 9.0 and re-installed only Adobe 8.0 Pro , thinking there was a problem there. Did not work.
    I googled for more answers, did not find anything else.
    I am able to "print as Adobe PDF", I can create normal PDF documents, but not the Forms.
    I used that option all the time for work. Can someone help me please?!!
    Thanks!
    Gwen

    Bill, it worked!!
    I updated to 8.1.6 and now I can use an electronic document to create a form.
    Thank you!
    I have another question: in the past, to enable Acrobat READER users to fill out a form and save it on their computer, all I had to do is "Enable Usage Rights in Adobe Reader" in the "advanced" menu of Acrobat Pro.
    I did just that but my colleagues who have Adobe Reader 9 cannot fill the form. It appears as a scanned PDF document to them.
    Any idea why?!
    Gwen

  • Opening HCM PDF forms from UWL

    Dear Friends,
    I am working in an assignment which involves the following
    Portal version 7.01 SP3
    HCM Process and Forms
    ESS and MSS
    UWL
    I am doing the following steps
    1. logged in as a manager
    2.Go to Team
    3. Initiated the 'start process' to change the work timings for an employee
    4.Change the timings in the presented PDF form
    5.Send the form
    6. logged in as HR Admin
    7. Able to see the work item in the UWL inbox
    8. On clicking the from the UWL inbox portal does not open the submitted PDF form, rather opens start process.
    May I request you to help me in opening the PDF form from the UWL, please.
    Regards,
    Tarani

    Hi Terani,
    We are also facing the same issue with HCM forms in Portal. So could you please update how did you resolve this issue.
    Thanks,
    Naveen Kumar

  • I am working in Adobe Acrobat 9 Pro and just created a pdf form from a MS Word document. I need to find out how to have a date field in my form which will update automatically. Can some one out there help me?

    I am working in Adobe Acrobat 9 Pro and just created a pdf form from a MS Word document. I need to find out how to have a date field in my form which will update automatically.

    Update automatically under which circumstances, exactly?

  • Creating a PDF form from a docx or xlsx

    Hello,
    Pulling my hair out over here... Can you help me out?
    I am trying to create a PDF form from either a word or an excel file.
    When I choose File > Create > PDF Form, I get the dialouge box asking to use either a file or scan from paper. Choosing file, then hitting next shows the choice of current document or browse for file. I browse for file, find my docx file, but it shaded out. Docx or xlsx does not appear in the "show" drop down below, which suggests that this function doesn't support these formats. HUH?
    I have read & watched the tutorials linked below, both of which clearly say Word and Excel are supported.
    http://help.adobe.com/en_US/acrobat/pro/using/WSB3F26303-0F1D-494a-BC55-7BF7F6684B4D.html
    http://tv.adobe.com/watch/learn-acrobat-x/getting-started-creating-simple-forms/
    Then I noticed a difference in the create window from the video, to my version...
    The video says "(PDF, Word, Excel or other file format)":
    My pop-up says ONLY PDF:
    Whats going on?
    I am using:
    MAC OSX 10.7.4
    Office 2011 MAC
    Acrobat X Pro 10.1.3
    Only way I can create a Form from Word files is to first print it to PDF, then use the form wizard on the PDF file... Which seems to have POOR results in auto-recognizing fields.
    PLEASE HELP Adobe!
    Thanks.

    I just got Acrobat X for my mac, for a class.  I am SO frustrated.  Almost everything in the class focuses on PDFMaker options.   The 'save as adobe pdf' or save as pdf options have zero functionality.  So I now own PDF software that doesn't really function on a MAC, and have to go to a windows machine.  I keep reading that it is a Microsoft problem, but I don't know how that can be when the software I thought I bought is this fancy PDF software that converts everything!!
    I asked a tech today if there were 'any' adobe work-arounds for this and basically the answer is to save PDF with no attribute functionality.  Period.
    Wasted $$ for me

  • I created a pdf form from a Word doc with 9 pt aerial font formatting; the text on the pdf form is aerial 9 pt, but the fields are formatted in courier 12 pt - How do I reformat the font in the fields??

    I created a pdf form from a Word doc with 9 pt aerial font formatting; the text on the pdf form is aerial 9 pt, but the fields are formatted in courier 12 pt - How do I reformat the font in the fields??

    You can set up a temporary button (or link, bookmark, etc.) and add the following JavaScript action:
    // Mouse Up script for a temporary button (or bookmark, etc.)
    // Change the font and font size for all text fields in this document
    for (var i = 0; i < numFields; i += 1) {
        var f = getField(getNthFieldName(i));
        if (f.type === "text") {
            f.textFont = font.Helv;
            f.textSize = 9;
    It also sets the font size, but you can remove that line if you don't need to do that.

  • I need to add an attachment to a pdf form from the SBA it is OIC_TABS_NGPC_nl.pdf

    I need to add an attachment to a pdf form from the SBA it is OIC_TABS_NGPC_nl.pdf

    Do the people who made the form SAY you can add an attachment? If not, do not consider it. The form will probably be read by a computer, so it will only look in the form fields provided.

Maybe you are looking for