How to display the return message in popup window

Hi Experts,
In WDA i want to display the return message through popup window.
Regards,
M.Chella Meenal.

hi Chella Meenal ,
you can generate the popup using popup factory class also , look at the below sample code for displaying message in a popup , and you can do your own configurating like visible , enable the buttons you want ..
data:
    lr_component type ref to if_wd_component,
    ls_conf type wdr_popup_to_confirm,
    lt_texts     type string_table.
  ls_conf-window_position = '1'.
  ls_conf-button_1-text = 'OK'.
  ls_conf-button_1-icon = 'ICON_OKAY'.
  ls_conf-button_1-enabled = 'X'.
  ls_conf-button_1-visible = CL_WD_UIELEMENT=>E_VISIBLE-VISIBLE.
  ls_conf-button_2-visible = CL_WD_UIELEMENT=>E_VISIBLE-NONE.
  ls_conf-button_cancel-visible = CL_WD_UIELEMENT=>E_VISIBLE-NONE.
  lr_component = wd_comp_controller->wd_get_api( ).
  append 'some text' to lt_texts.
  cl_wd_popup_factory=>popup_to_confirm(
      component        = lr_component
      text             = lt_texts
      CONFIGURATION    = ls_conf
      window_title     = 'some title' ).
Regards
Chinnaiya P

Similar Messages

  • How to display the eror message in the iView

    Hi
    I want to check the user input in the client side and display an error message in the iView instead of displaying the error message as an alert
    it is ok when I tried to do it as an alert
    alert('ERROR MESSAGE');
    but the problem is how to display the error message as a text in the iView ...
    I wrote the below code..
    any one can see it and has any sugestion?
    Thanks
    =============
    <%@ taglib uri="tagLib" prefix="hbj" %>
    <%
    String compid = "";
    String message = "";
    %>
    <hbj:content id="MyContent">
    <hbj:page title = "Selection Screen">
    <hbj:form id = "myForm">
    <br>
    <br>
    <br>
    <center>
    <H3>Benefits Statement </H3>
    <H4>Selection Screen</H4>
    <hbj:gridLayout
    id="FSSLayout"
    debugMode="False"
    width="40%"
    cellSpacing="5"
    >
    <hbj:gridLayoutCell
    rowIndex="1"
    columnIndex="1"
    width="10%"
    horizontalAlignment="LEFT"
    style="WildStyle"
    >
    <hbj:label
    id="label_inputPernr"
    required="TRUE"
    text="Personal Number:"
    design="LABEL"
    labelFor="inputPernr"
    />
    </hbj:gridLayoutCell>
    <hbj:gridLayoutCell
    rowIndex="1"
    columnIndex="2"
    width="40%"
    horizontalAlignment="LEFT"
    >
    <hbj:inputField id = "inputPernr"
    >
    <%
    compid=MyContent.getParamIdForComponent(inputPernr);
    %>
    </hbj:inputField>
    </hbj:gridLayoutCell>
    <hbj:gridLayoutCell
    rowIndex="10"
    columnIndex="1"
    width="40%"
    horizontalAlignment="CENTER"
    colSpan="2"
    >
    <hbj:button id = "myButton" text="Submit.." design="EMPHASIZED"
    tooltip="Click me to submit this form" onClick="ClickEvent" onClientClick="validRequired()">
    </hbj:button>
    </hbj:gridLayoutCell>
    </hbj:gridLayout>
    </center>
    <p font="Arial" size=20><%= message%></p>
    </hbj:form>
    <SCRIPT LANGUAGE="Javascript">
    function validRequired()
    var myvar = document.getElementById('<%=compid%>').value;
    var ivID='<%=componentRequest.getComponentContext().getContextName()%>';
    if (myvar = " ")
    message = "Enter Employee Number";
    ivuRefresh(ivID);
    htmlbevent.cancelSubmit=true;
    </SCRIPT>
    </hbj:page>
    </hbj:content>

    No problem, here is an example of some html code and javascript that you can adapt to your needs. You can display this standalone to see how it works.
    I hope this helps
    <html>
         <head>
              <script language="JavaScript">
                   function validateForm(){
                        if(document.getElementById("nameField").value == "")
                             document.getElementById("errormessage").innerHTML = "Please enter the Name";
                        else if(document.getElementById("ageField").value == "")
                             document.getElementById("errormessage").innerHTML = "Please enter the Age";
                        else if(document.getElementById("idField").value == "")
                             document.getElementById("errormessage").innerHTML = "Please enter the id";                         
                        else
                             document.getElementById("errormessage").innerHTML = "";
              </script>
         </head>
         <body>
              <table border="0" cellpadding="0" cellspacing="0">
                   <tr>
                     <td>Name</td>
                     <td><input type="input" id="nameField" name="nameField"></td>
                   </tr>
                   <tr>
                     <td>Age</td>
                     <td><input type="input" id="ageField" name="ageField"></td>
                   </tr>
                   <tr>
                     <td>Id</td>
                     <td><input type="input" id="idField" name="idField"></td>
                   </tr>
                   <tr><td><font color="red"><span id="errormessage"></span></font></td></tr>
                   <tr><td><input type="button" name="validate" onClick="validateForm()" value="Click to validate"/></td></tr>
              </table>
         </body>
    </html>

  • How to display the error message on screen in display mode

    Hi all,
    How to display error message as as status message on the screen(module pool).
    The requirement is if I call the screen, it should get with the error message in the status bar. If I write with error message 'E' error mesage information displays and when I click on exit, it lives the current transaction.
    Thank you!
    Prasad

    Hi,
    Try as below.
    MESSAGE IXXX DISPLAY LIKE 'E'.
    LEAVE TO SCREEN XXXX.
    After displaying the information message like E, leave to the screen you want to navigate or can also navigate to the transaction required.
    Regards,
    Nangunoori.

  • How to display the return value of a function in a text field

    Hi,
    I have 2 textfields in a page.
    i> Empno
    ii> Salary
    The requirement is,
    i. Enter an Employee No.
    ii. On click of the 'SUBMIT' button a process would be executed which calls a function (or procedure with out parameter) which returns the Salary of the given Employee.
    iii. Need to display the salary to the 2nd textfield (Salary).
    Here is my process:
    i. If procedure call-- :P2_X is a page text field and out parameter.
    begin
    Pri_test_PROC(:P2_EMPNO,:P2_X);
    end;ii. If Function call --
    begin
    :P2_X:=Pri_test_PROC(:P2_EMPNO);
    end;
    Issue:
    The process is not getting executed and returning the process error message.
    Could anyone please give me a pointer, how to overcome the issue. Or if this is not the right way, then what is the work around.
    Regards
    Antara

    Antara,
    1. Clue about the error - yes, when I see the error message.
    2. What happens if you try to create a procedure like this:
    CREATE OR REPLACE PROCEDURE fetch_sal (in_emp IN NUMBER, out_sal OUT NUMBER)
    IS
    BEGIN
       FOR c IN (SELECT sal
                   FROM emp
                  WHERE empno = in_emp)
       LOOP
          out_sal := c.sal;
       END LOOP;
    END;and then run this in SQL Plus:
    DECLARE
       v_sal   VARCHAR2 (20);
    BEGIN
       fetch_sal (7839, v_sal);
       DBMS_OUTPUT.put_line (v_sal);
    END;What do you get displayed?
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://htmldb.oracle.com/pls/otn/f?p=31517:1
    -------------------------------------------------------------------

  • How to display the Output messages on LabVIEW

    Hi,
    I'm building a simple user interface on LabVIEW and I have the following question:
     - TestStand has an Output Tab where I display some messages using Engine.OutputMessage; How can I do the same thing on my UI?
    I've attached a printscreen of my TestStand sequence as an example of what I want do do on LabVIEW.
    I apreciate all the help.
    Thanks in advance.
    Regards,
    Daniel Coelho
    Daniel Coelho
    VISToolkit - http://www.vistoolkit.com - Your Real Virtual Instrument Solution
    Controlar - Electronica Industrial e Sistemas, Lda
    Attachments:
    TS PrintScreen.JPG ‏137 KB

    Sorry, from your post in the LabVIEW board I did not understand that it was the Output message that you were looking for.
    I thought you wanted the results from your test steps displayed on the user interface. 
    It is the “Output Panel” in the sequence editor that displays your output message, but I do not know if there is default Output panel activeX indicator for user interface that the TestStand engine would update automatically like it does the execution view.
    Maybe someone else knows 
    As also pointed out, the UI messages is your other option.
    The Output Message event number is 40 
    http://zone.ni.com/devzone/cda/epd/p/id/3879
    UIMsg_OutputMessages–(Value: 40) TestStand sends this message at periodic intervals when it holds references to output messages that calls to the OutputMessage.Post method queue. TestStand transfers the queued messages to an OutputMessages collection attached to the UIMessage.ActiveXData property for this event. An application that processes output messages should copy the output message references from the collection in UIMessage.ActiveXData to its own private OutputMessages collection by passing its private collection to the OutputMessages.CopyMessagesToCollection method. An application calls the Engine.NewOutputMessages method to create a private OutputMessage collection. TestStand generates this event only if the Engine.OutputMessagesEnabled property is True. Because there can be more than one handler for this event, the application should not modify the OutputMessages collection the UIMessage.ActiveXData property holds.
    Omar
    Message Edited by OmarGator on 10-09-2008 10:12 AM

  • How to display the error message during the web dynpro application runtime

    hi,
        I'm a java developer,During i 'deploy and run ' a web dynpro application on server-1,if the application have some runtime errors. there are displayed many infomation about the runtime error,such as exception track,etc.
        But when i do the same on server-2,there just show something like:
                500   Internal Server Error
                                    SAP NetWeaver Application Server 7.00/Java AS 7.00
                Failed to process request. Please contact your system administrator.
    but the server-1 will stop the j2ee engine. 
    how can do i make server-2 show detail error message as server-1. when i debug web dynpro application need these infomation.
    Appreciate your inputs...
    (Note:server-1 and server-2 have same software version)
    Edited by: BingLin Zhong on Feb 18, 2008 2:13 AM

    The Sap-Notes 962319:
    1. Check in the Visual Administrator, "Licensing Adapter" -> "General" -> "SystemType" !
    If it is set to "DEVELOPMENT_MODE", verbose error messages are shown.
    If it is undefined, proceed with the next step.
    If it is set to something else, only exception IDs are shown. In this case the only chance is to search for this exception ID in the default traces.
    2. If the system type is undefined, then in the Config Tool "Configurations" -> "webdynpro" -> "sap.com" -> "tcwddispwda" -> "Propertysheet default" -> "DevelopmentMode" is evaluated. If it is "true", verbose error messages are shown.
    3. If verbose error messages are required but still the short version is shown, you probably face an error message that is not raised by Web Dynpro but by other components of the NetWeaver. In the Visual Administrator set "Properties" -> "HTTP Provider" -> "DetailedErrorResponse" to "true".
    4. In addition to the error page shown in the browser or client, important messages - including error messages and stack traces - are written to the log and trace files, e.g. to the default traces usr\sap\<SID>\<instance>\j2ee\cluster\server<number>\log\defaulttrace.trc.<number>.
    a) In some cases, when an exception ID is included in the error message, the detailed error message can easily be retrieved in the log file.
    b) When no exception ID is given, you have to search for the detailed error message in the log specifying time stamp and/or user ID.
    Always consider restarting the system after making changes on the settings.
    It is not recommended to switch the "SystemType" to an inappropriate value just for viewing verbose error messages. The system type potentially affects framework, applications and licensing in an perhaps unintended way.
    In the past there was no distinction between different system types regarding error messages. For security reasons this distiction has been introduced. It is not intended to show stack traces in non-development systems in the future. SAP does not provide workarounds or patches to enable such a behaviour again.

  • How to display BAPI return message as a pop up

    Hi,
    I am able to get BAPI return message but my requirement is to display these BAPI return messages as pop up's like alerts in javascript.
    I am using abstract portal component.
    any suggestions.
    Regards
    Praveen

    Hi,
    Place a hidden field in your abstract portal component like this:
    <input type ="hidden" name ="returnedmessage" value=<i>the variable returned from JCO</i>>
    In addition to this:
    <script language = "javascript">
    if (document.<i>formname</i>.returnedmessage.value != null || document.<i>formname</i>.returnedmessage.value != "")
    alert(document.<i>formname</i>.returnedmessage.value);
    </script>
    If you are transferring your code to a JSP it would less cumbersome else you would have to enclose all this in response.write(); statements.
    Regards,
    Prem

  • How to get the return message after running BD20 tranaction ?

    Hi Gurus,
    My requirement is to Post vendor invoice through ALE/IDOC ( Inbound IDOC ).
    - For that I had generated the IDOC using  Function module 'IDOC_INBOUND_WRITE_TO_DB '
    - Then I had processed that generated IDOC by calling the standard program rbdapp01(BD20-Tranaction ) using the below statment
    SUBMIT rbdapp01 WITH SELECTION-TABLE lt_seltab .
    Could any one suggest me how to get the report output of standard program (rbdapp01) to an internal table so that I dispaly as an seperated report like Posted Document number with messages or Error message
    Suggest me any Function module or any other standard program to process the IDOC so that I can fulfill my requirement.
    Regards
    Paul

    Use can read the IDOC status after processing...
    Eg.
      SELECT * FROM edidc INTO TABLE t_idoc_control_tmp
          FOR ALL ENTRIES IN t_update WHERE docnum = t_update-docnum.
    and then add your own logic IF SY_SUBRC EQ 0.
    I hope this will help you.
    Regards,
    Amey

  • How to fectch the error message from popup?

    i am able to recognize pop message at the the time recording byt at the time of playback it's unable to find that.

    When u call a BAPI there will be Return structure. u need to pass the internal table to that function module. when the function module is executed the internal table is filled with the messages. u can loop at that internal table where message type is 'E' and process the message.
    Check this :
    DATA:IT_PERSONALDATA LIKE STANDARD TABLE OF BAPIKNA101_1 WITH HEADER LINE,
         IT_COPYREFERENCE LIKE STANDARD TABLE OF BAPIKNA102 WITH HEADER LINE,
         RETURN LIKE STANDARD TABLE OF BAPIRETURN1 WITH HEADER LINE.
    CALL FUNCTION 'BAPI_CUSTOMER_CREATEFROMDATA1'
      EXPORTING
        PI_PERSONALDATA              = IT_PERSONALDATA
      PI_OPT_PERSONALDATA          = PI_OPT_PERSONALDATA
      PI_COMPANYDATA               = PI_COMPANYDATA
      PI_OPT_COMPANYDATA           = PI_OPT_COMPANYDATA
      PI_CONSUMEREN                = PI_CONSUMEREN
        PI_COPYREFERENCE             = IT_COPYREFERENCE
      PI_CREDIT_CONTROL_FLAG       = PI_CREDIT_CONTROL_FLAG
    IMPORTING
       CUSTOMERNO                   = V_CUSTOMERNO
       RETURN                       = RETURN.
    CALL FUNCTION 'BAPI_TRANSACTION_COMMIT'
      EXPORTING
        WAIT = 'X'.
    APPEND RETURN.
    LOOP AT RETURN.
      WRITE:/ RETURN-TYPE, RETURN-MESSAGE.
    ENDLOOP.
    Regards,
    Swathi

  • How to display the information message in the end in BDC

    Dear All,
    I have been submitting a BDC for FB01, in a dialog program of mine.
    The BDC gets executed successfully but it does not display the 'Documnet No....generated' information message in the end.
    I have even written the following code in the BDC, after call transaction, to accomplish this, by assigning the value of genno (variable) to sy-msgv1, but it's not working.
    call transaction 'FB01' using bdcdata1 mode 'E'.
      message id sy-msgid type sy-msgty number sy-msgno
            with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      genno = sy-msgv1.

    Hi,
    try this its easy .
    create an internal table e_report for sucess with the fields you want to display .like the same for F_tab for failure .
    so finally u will be having the success record in e_report and the failure in f_itab.
    call transaction 'FB09' using bdcdata MODE 'N' MESSAGES INTO IT_ERROR.
    IF sy-subrc eq 0.
      E_report-status = 'Sucessfully Updated'.
      e_report-belnr = itab-belnr.
      e_report-year = fiscalyear.
      APPEND E_report.
    else .
       F_tab = itab.
       F_tab-year = fiscalyear.
       F_tab-status = 'FAILED'.
       APPEND F_tab.
    finally print this
    sort e_report by  belnr ascending.
    LOOP AT E_report.
        at FIRST .
           WRITE:/'**********SUCCESSFUL RECORDS ARE **********'.
           FORMAT COLOR 6.
           WRITE:/ 'Document Numer',20 'Year',35'Status',54 ''.
        ENDAT.
        FORMAT COLOR 3.
        write:/ E_report-belnr,20 E_report-year ,35 E_report-status.
        FORMAT COLOR OFF.
       at LAST.
         write:/ 'Total No.Of Successful Records:',sy-tabix.
         FORMAT COLOR OFF.
       ENDAT.
       RESERVE 20 LINES.
    ENDLOOP.
      IF F_tab is initial.
           FORMAT COLOR 1.
           WRITE:/ ' NO Errored Files'.
           FORMAT COLOR OFF.
      ENDIF.
    WRITE:/ SY-ULINE.
    new-PAGE.   " to display in a  new page
    sort f_tab by  belnr ascending.
    LOOP AT F_tab.
        at FIRST .
           WRITE:/'**********FAILED RECORDS ARE **********'.
           FORMAT COLOR 6.
           WRITE:/ 'Document Numer',20 'Year',35'Status',54 ''.
        ENDAT.
           FORMAT COLOR 5.
           WRITE:/ f_tab-belnr ,20 F_tab-year, 35 F_tab-status.
        at LAST.
         write:/ 'Total No.Of Failed Records:',sy-tabix.
        ENDAT.
    ENDLOOP.
    ENDIF.
    if they want to display in the excel sheet pass the internal table to the F.M.
    plz motivate me.
      by rewards.
    thanks
    vinoth

  • How to display the status message based on student marks..

    Hi all,
    i have student table that has columns mark1,mark2,mak3...
    i want to display the student name,staus as pass or fail based on the marks.. in a single query..
    if the student score above 30 in all the subject i should display the status as pass other wise fail ( note:- status is not a column in the table)
    Thanks

    select e.student_name
          ,e.mark1
          ,e.mark2
          ,e.mark3
          ,decode(pass.flag,'Y','PASS','FAIL') status
    from   exam e
           , (select e2.student_id,'Y' flag
              from   exam e2
              where  e2.mark1 > 30
              and    e2.mark2 > 30
              and    e2.mark3 > 30) pass
    where e.student_id = pass.student_id (+);
    STUDENT_NAME      MARK1      MARK2      MARK3 STATUS
    CNAME                40         50         60 PASS  
    DNAME                60         70         80 PASS  
    ANAME                20         30         40 FAIL  
    BNAME                30         40         50 FAIL Edited by: JamesK on May 30, 2013 12:38 PM
    Edited by: JamesK on May 30, 2013 12:40 PM

  • How to display a PDF document in popup window

    Hi,
    I have a requirement where i need to display a PDF document to be obtained from a virtual repository and then display it on a popup window.
    Thanks
    DS
    PS: any code snippet or link explaining the above will be helpful

    Use should the ShowProperty servlet in a link or javascript, e.g.:
    <a href="/mywebapp/ShowProperty/path/to/pdf/node
    target="someOtherWindow">pdf</a>
    pdf
    Or, with dyamic node retrieveal (from search or contentSelector,
    assuming node is the pdf Node):
    <a href="/mywebapp/ShowProperty<cm:getProperty node='<%=node%>'
       name='cm_path' conversionType='url'/>
    target="someOtherWindow">pdf</a>
    <a href="javascript:window.open(
       '/mywebapp/ShowProperty<cm:getProperty node=<%=node%">"
    name="cm_path" conversionType="url"/>',
    'SomeOtherWindow',
    'height=400,width=400,scrollbars=auto,resizeable=yes');return false;">
    pdf</a>
    Greg
    Sanjay Datta wrote:
    Hi,
    I have a requirement where i need to display a PDF document to be obtained from a virtual repository and then display it on a popup window.
    Thanks
    DS
    PS: any code snippet or link explaining the above will be helpful

  • How to close the adobe forms in popup windows once.

    hi,expert..
    i show a adobe form in a popup windows in my webdynpro program...but i find out that i at least click twice on the "CLOSE" button on the right top of the window.....how can i modify my program to  close the window once..
    the original codes are as follow:
    method onactionprint .
       data lo_nd_zhrhap_vp_app_01 type ref to if_wd_context_node.
      data lo_nd_zhrhap_t_document type ref to if_wd_context_node.
      data lt_zhrhap_t_document type wd_this->elements_zhrhap_t_document.
      lo_nd_zhrhap_vp_app_01 = wd_context->get_child_node( name =
    wd_this->wdctx_zhrhap_vp_app_01 ).
      lo_nd_zhrhap_t_document = lo_nd_zhrhap_vp_app_01->get_child_node(
    name = wd_this->wdctx_zhrhap_t_document ).
      lo_nd_zhrhap_t_document->get_static_attributes_table(
        importing
          table = lt_zhrhap_t_document ).
    DATA lo_nd_zhrhap_s_app_leader TYPE REF TO if_wd_context_node.
    DATA lo_el_zhrhap_s_app_leader TYPE REF TO if_wd_context_element.
       data ls_zhrhap_s_app_leader type
    wd_this->element_zhrhap_s_app_leader.
    lo_nd_zhrhap_s_app_leader = lo_nd_zhrhap_vp_app_01->get_child_node(
    *name = wd_this->wdctx_zhrhap_s_app_leader ).
    lo_el_zhrhap_s_app_leader = lo_nd_zhrhap_s_app_leader->get_element(
    lo_el_zhrhap_s_app_leader->get_static_attributes(
       IMPORTING
         static_attributes = ls_zhrhap_s_app_leader ).
    DATA lo_nd_zhrhap_s_dates TYPE REF TO if_wd_context_node.
    DATA lo_el_zhrhap_s_dates TYPE REF TO if_wd_context_element.
       data ls_zhrhap_s_dates type wd_this->element_zhrhap_s_dates.
    lo_nd_zhrhap_s_dates = lo_nd_zhrhap_vp_app_01->get_child_node( name
    *= wd_this->wdctx_zhrhap_s_dates ).
    lo_el_zhrhap_s_dates = lo_nd_zhrhap_s_dates->get_element(  ).
    lo_el_zhrhap_s_dates->get_static_attributes(
       IMPORTING
         static_attributes = ls_zhrhap_s_dates ).
    采集表名称和日期
      data lo_nd_if_data type ref to if_wd_context_node.
      data lo_el_if_data type ref to if_wd_context_element.
      data ls_if_data type wd_this->element_if_data.
      lo_nd_if_data = wd_context->get_child_node( name =
    wd_this->wdctx_if_data ).
      lo_el_if_data = lo_nd_if_data->get_element(  ).
      lo_el_if_data->get_static_attributes(
        importing
          static_attributes = ls_if_data ).
      ls_zhrhap_s_dates-valid_begda = ls_if_data-begda.
      ls_zhrhap_s_dates-valid_endda = ls_if_data-endda.
    DATA lo_el_zhrhap_vp_app_01 TYPE REF TO if_wd_context_element.
       data ls_zhrhap_vp_app_01 type wd_this->element_zhrhap_vp_app_01.
       data lv_description like ls_zhrhap_vp_app_01-description.
    lo_el_zhrhap_vp_app_01 = lo_nd_zhrhap_vp_app_01->get_element(  ).
    lo_el_zhrhap_vp_app_01->get_attribute(
       EXPORTING
         name =  `DESCRIPTION`
       IMPORTING
         value = lv_description ).
    REPLACE ALL OCCURRENCES OF '类别:' in lv_description with ''.
      lv_description = ls_if_data-stext.
      data l_is_ok    type boole_d.
      data pdf_source type xstring.
      data l_msg      type ref to cl_hrpa_message_list.
      create object l_msg.
      call method zcl_hr_appraisal_utility=>print_contract_direct
        exporting
        form_type           = 'COD'
          zhrhap_t_document   = lt_zhrhap_t_document
          zhrhap_s_dates      = ls_zhrhap_s_dates
          zhrhap_s_app_leader = ls_zhrhap_s_app_leader
          description         = lv_description
        job_description     =
          message_handler     = l_msg
         importing
          is_ok               = l_is_ok
          pdf_xstring         = pdf_source
      check l_is_ok is not initial and pdf_source is not initial.
      data lo_nd_pdf type ref to if_wd_context_node.
      data lo_el_pdf type ref to if_wd_context_element.
      data ls_pdf type wd_this->element_pdf.
      data lv_source like ls_pdf-source.
      lo_nd_pdf = wd_context->get_child_node( name = wd_this->wdctx_pdf ).
      lo_el_pdf = lo_nd_pdf->get_element(  ).
      lo_el_pdf->set_attribute(
        exporting
          name =  `SOURCE`
          value = pdf_source ).
    *-->ADOBE View embeded to ViewContainer UI
      data: lr_view               type ref to if_wd_view_controller,
            lr_api_main           type ref to if_wd_component,
            lr_window_man         type ref to if_wd_window_manager,
            comp_usage            type ref to if_wd_component_usage,
            l_title               type string value '打印合同',
            lr_window             type ref to if_wd_window.
      lr_view = wd_this->wd_get_api( ).
      lr_api_main = wd_comp_controller->wd_get_api( ).
      lr_window_man = lr_api_main->get_window_manager( ).
    l_title = wd_colr_mp_controller->model->get_text( '006' ).
      call method lr_window_man->create_window
        exporting
          modal        = abap_true
          window_name  = 'POPUP'
          title        = l_title
          button_kind  = if_wd_window=>co_buttons_yesno
         message_type = if_wd_window=>co_msg_type_none
          default_button = if_wd_window=>co_button_yes
        receiving
          window       = lr_window.
      lr_window->open( ).
    endmethod.
    looking forward to your help....thanks in advance

    Ping,
    1st, see the Markup formatting options over on the right part of the screen - if you wrap your code between the code tags it will read MUCH better.
    2nd, I can't replicate this issue - we have several PDFs opening in new windows & we only need to click once on the clost 'X' - how are you calling the PDF in a new window?
    If you can't find a final resolution, an alternative would be to place a LinktoAction on your web dynpro application somewhere that makes sense which would close the window for you.
    We do this on Sucess Message Views...
    You can simply add the link to action to the screen, and in the event handler use
       data : l_view_cntr type ref to if_wd_view_controller,
           l_win_cntr  type ref to if_wd_window_controller,
           l_window    type ref to if_wd_window,
           l_parameter_list  type wdr_event_parameter_list,
           l_parameter       type   wdr_event_parameter,
           l_val type ref to data.
    field-symbols <fs> type any.
    l_view_cntr = wd_this->wd_get_api( ).
    l_win_cntr  = l_view_cntr->get_embedding_window_ctlr( ).
    l_parameter-name = 'CLOSE_WINDOW'.
    create data l_val type c.
    assign l_val->* to <fs>.
    <fs> = 'X'.
    l_parameter-value = l_val.
    insert l_parameter into table l_parameter_list.
    l_win_cntr->if_wd_view_controller~fire_plug(
    exporting plug_name = 'EXIT_PLUG'
               parameters = l_parameter_list ).
    Make sure you have an Exit plug on your Window with Plug Type EXIT.

  • How to display value of variable in popup window

    Hi Experts ,
                   I need to display a variable which imported from call method and i have to display in popup window
               (  need code ) please help

    Hi Neeraj,
    You can use modal dialog box,
    create a view and window also that should be displayed as pop up in the same component and use the following code
    to display it.
    Concept is we are using the window that embeded with view is dispalyed as modal dialog box.
    Before calling the window, you should populate the data that mapped in the view.
    DATA lo_window_manager TYPE REF TO if_wd_window_manager.
    DATA lo_api_component TYPE REF TO if_wd_component.
    DATA lo_window TYPE REF TO if_wd_window.
    lo_api_component = wd_comp_controller->wd_get_api( ).
    lo_window_manager = lo_api_component->get_window_manager( ).
    wd_comp_controller->go_window
    = lo_window_manager->create_window(
    window_name = u2019POPUP_WINDOWu2019
    title = 'welcome'
    close_in_any_case = abap_false
    message_display_mode = if_wd_window=>co_msg_display_mode_selected
    close_button = abap_false
    button_kind = if_wd_window=>co_buttons_ok
    message_type = if_wd_window=>co_msg_type_none
    default_button = if_wd_window=>co_button_ok ).
    Regards,
    Meera

  • How to handle BAPI RETURN message?

    Hi ,
    I developed a bapi ,it is calling from java  application . i don't konw how to send the return message to java application .Pl any one help out this problem.
    Thanks&Regards,
    Pratap

    bapi's normally have a return parameter of type BAPIRETURN (structure) or BAPIRET (internal table) that contain the result messages from a bapi. So if you develop your own bapi you should add this kind of export parameter.
    regards,
    Hans

Maybe you are looking for

  • Platform Migration Clarification

    Greetings, We are doing a platform migration of an E-Business R12.1.1 environment. We originally got to R12.1.1 by directly upgrading from 11.5.9.2 back in December, 2009. Our source platform is: W2003 runs Apache and Forms, and "everything else" is

  • Error in opening of Pdf file attachment

    hi, i am sending pdf file as an attachment to mail recipient, after receiving that pdf attachment when the user tries to open that attachment he is getting the following error message. *"Adobe reader could not open file because it is either not a sup

  • [SOLVED] Error 'Your source tree might be broken' in kernel26zen-git

    Since a few days I am trying to rebuild my custom ZEN-kernel. After updating the sources everything was built using my own config, that worked many times before. However, makepkg halted every time I tried to build the kernel, saying: ==> Building ker

  • User defaults for cs

    hi everybody, does anybody know a good way to set the various prefs of the creative suite like transparency flattener presets, GREP queries, workspaces, color profiles, etc. as a default for network users which come from an xserve? thx in advance

  • Business area is getting populated automatically

    Hi, I came across a situation where some time Business area is getting populated automatically in some of the Maintenance order. I have checked the reference object, cost centre, Plant level, WBS element etc, we have not maintained the business area