Send a mail to the agents

hi
my question is send the mail to the assigned agents after the task is go through a condition, and condition fails it also have send mail and true it has send mail to the agents. I have designed the workflow and all other parts are working fine when my condition reject, it never works

Assigned agents of what step? There are no assigned agents in a condition step.

Similar Messages

  • How to create  a procedure to send a mail if the Database is down?

    Hi,
    I have created the below procedure to send a mail if the count is less than 1300. It scheduled daily @ 15 30 hrs. Its fine.
    CREATE OR REPLACE procedure SCOTT.hrsmail
    is
    v_count number;
    begin
    Select count(*) into v_count from emp;
    if v_count < 1300
    then
    UTL_MAIL.send(sender => '[email protected]',
    recipients => '[email protected]',
    cc => '[email protected]',
    bcc => '[email protected]',
    subject => 'Testing the UTL_MAIL Package',
    message => 'If you get this, UTL_MAIL package
    else
    null; --what you want to do here
    end if ;
    end;
    Sometime the Database is down, so the job is not running.
    How to create a procedure to send a mail if the database is down?
    Pls help me. Its highly appreciated.
    Thanks
    Nihar

    nihar wrote:
    How to create a procedure to send a mail if the database is down?And what if the database is up, but the network down? Or the database up and mail server down? Or mail server undergoing maintenance?
    There are loads of "+What if's+" - and in that respect, playing "+What if database is down..+" in this case does not make any sense. You do not use the database to monitor its own up/down status. You do not rely just on SMTP as notification protocol that the database is down.
    The correct approach would be using something like SNMP as the monitoring protocol. A monitoring system that can process SNMP and perform some basic root cause analysis (e.g. network to the database server down, database server status unknown). And this system supporting notification methods like SMTP, SMS and so on.

  • How to Send a Mail From the Oracle Applications.

    Hi,
    I was assigned a task to send a mail from the front end i.e., from oracle applications.
    but i have no idea.
    i am working on oracle apps R12.1.1 and 10g reports.
    First i have to create an rdf file and that rdf file i want to send as an attachment through mail from the apps.
    Any Advice will be of great help and i will follow accordingly.
    Thanks in Advance,
    Regards,
    Bharathi.S

    Hi,
    I was assigned a task to send a mail from the front end i.e., from oracle applications.
    but i have no idea.
    i am working on oracle apps R12.1.1 and 10g reports.
    First i have to create an rdf file and that rdf file i want to send as an attachment through mail from the apps.
    Any Advice will be of great help and i will follow accordingly.
    Thanks in Advance,
    Regards,
    Bharathi.S

  • Any changes in PA30 need to send a mail to the Managers outlook inbox

    Hi,
    Any changes in PA30 (ESS) need to send a mail to the Managers outlook inbox  .
    Kindly let me know the Standard workflow template and  to built the Custom function module in Rule .
    Thanks in advance,
    Richard A

    <i>Any changes in PA30 (ESS) need to send a mail to the Managers outlook inbox</i>
    If its just an email do u need a workflow for it? Configure dynamic actions which will call a subroutine when a change is made to the infotype and send email from that subroutine using SO_NEW_DOCUMENT_SEND_API1.(you can include the necessary logic for determining the approver in the same subroutine).
    Thanks,
    Prasath N

  • My macbook pro with OS 10.6.7 'mail' program does not send my mail through the IPS wireless, I am connected to. The message is my 'e-mail is rejected by the server'. It has been working until 5 days ago. The connection doctor says I am connected and no lo

    My macbook pro with OS 10.6.7 'mail' program does not send my mail through the IPS wireless, I am connected to. The message is my 'e-mail is rejected by the server'. It has been working until 5 days ago. The connection doctor says I am connected and no log in required.
    After trying lots I found now in 'Airport Utility is 'unable to detect any airport wireless devises.....'
    There is no provider to be seen in airport utility and only 'rescan' is an option with no results...
    even so I am connected and can browse the net receive mail etc. and the outgoing 'mail server' is set to the internet provider I am connected to.
    Can you enlighten me what can I do I need to use my e-mail program urgently !!!
    Thanks for your help

    I'm not sure what "IPS wireless" is, but unless you have an Apple Wi-Fi base station (such as a Time Capsule, AirPort Extreme, or AirPort Express), AirPort Utility won't see anything.
    You might try defining a new SMTP server to see if that will work any better.
    By the way, the subject field for these messages isn't intended to hold a lot of text.  Put a short description of your problem in the subject field and save the rest of your message for the body field.

  • Send reminder mails to the outlook

    Hi everyone,
    I have a scenario where i have a modeled deadline branch where if the deadline is missed i am sending recursive mails to the recipients using Rule in an activity .
    In the Rule i am using FM SO_NEW_DOCUMENT_ATT_SEND_API1 for sending mails . I need to send mails 3 times for every 5 mins . for that i have created a requested start deadline with time as 5 min .
    and a workflow element status with initial value as 0 . and  in the same branch i have used a container operation step where i am incrementing my status value by 1.
    and loop until condition is set to &status& = 3.
    i am receiving the reminder mail only once in my outlook and the status is set to 1.
    it is not getting incremented again . and hence no second reminder mails are coming in my outlook.
    Can any one please help .?
    Thanks !!

    I need to send mails 3 times for every 5 mins . for that
    i have created a requested start deadline with time as 5 min .
    I assume you have desigened the workflow template as below.
    1. A dialog step where the workitem will be sent for apprval.
    2. For the above dialog step you have defined both Requested start and Latest end of Modelled Deadline .
    3. In the newly generated branch you have inserted a loop and inside a loop you have defined a step to send mails. End condition for the loop is COUNT = 3.
    IF the case is like above then you modify the workflow design as below.
    1. Instead of inserting a loop in the deadline brach , you define it outside the deadline branch.
    2. Both Dialog workitem and deadline brach and its step must be included inside one loop.
    3. Now for the whole loop you deifine a condition in a such a way that the workitem should not miss the deadline and it should be in the completed status then only you will end the whole loop other wise you keep on looping it .
    I hope if you remodify the workflow as above i hope it works...

  • Send a mail to the customer when their order of type Residential Credit is booked

    Hi,
    We need to send a mail to the customer when their order of type Residential Credit is booked.
    I followed the below steps, but i could not write the code for sending email, can you please send me a sample code.
    Step1:
    =======
    Setup Processing Constraint on Order Header/Line for order booking
    *(Navigation : Setup --> Rules --> Security --> Processing Constraints)*
    a) Set Application : Order Management, Entity : Order Header
    b) Under constraints --> set Operation : Create, user Action : Raise Integration event, and make it enabled
    c) Condition --> Set Scope : Any, Validation Entity : Order header, record Set : Order, Validation Template : Booked and make it enabled too.
    Step2:
    ========
    Profile Option: Set "OM: Electronic Message Integration Event Sources" to be set to All
    Step3:
    ========
    Develop a code(Package) /workflow as per business requirement. e.g sending mail to customer when order is booked.
    Step 4:
    =======
    Open business event *"oracle.apps.ont.oi.xml_int.status"* through workflow Administrator responsibility. Include code/workflow in the subscription section of Business event.
    Navigation : WF Administrator Web application ---> Administrator Workflow --> Business Events
    Search Name : oracle.apps.ont.oi.xml_int.status, it will return 1 record, click on subcription...
    In this page include the function e.g CLN_CH_EVENT_SUBSCRIPTION_PKG.ADD_COLLABORATION_EVENT_SUB, if you are using WF, mention (e.g) wf_rule.default_rule in function & Workflow as OEEM/WRITE_HISTORY and enable it in this page..
    Thanks and Regards,
    Priya

    Just wanted to let you guys know that I still haven't received my MP3 player... Creative has had the MP3 player for 73 days now and they still haven't sent it back. Since last time I wrote here I got an e-mail from Creative saying they got the MP3 player on the 5th of the November and that somehow the status wasn't updated. Well, it's been 73 days now, care to send it away? I sent them and e-mail yesterday where I wrote that they could just send me the cash for it or a new MP3 player.
    If I don't receive my MP3 player in a near future I will contact "Allm?nna Reklamations N?mnden" (a Swedish "Consumerist"-like government sponsored organization that deals with people vs company legal cases).
    Again, I strongly advise everyone to not buy any more Creative products. Once they break you won't get the help you need.

  • Send a mail to the vendor at the time of approval with the attachment of PO

    Hi all,
    I want to send a mail to the vendor at the time of approval by attaching the pdf of that particular PO.
    How can I achieve this?
    I know the User Exit where the code should be written.
    But I want the solution for attaching the PDF of PO at the time of approval.
    Please help me in this regard.
    Edited by: vinil kumar aturi on Mar 16, 2009 7:52 AM

    Hi,
    Try Following Code to Send mail as PDF Attachment
    In this
    Smart form Name : ZSMART_MM_003
    This will send mail to EMAIL ADDRESS SPECIFIED IN VENDOR MASTER FK03
    This code is written for ME23n so we used nast-objky(10) for purchase order no you may replace it with your purchase order no
    and smart form name with your smart form name
    *-- Send Mail---
    *-- Function Module Call to get Customer Address (Email)--
    DATA: VENDOR TYPE ELIFN,
          ADDRNO TYPE ADRNR.
    DATA: atab-mail TYPE STRING.
    SELECT SINGLE LIFNR FROM EKKO INTO VENDOR WHERE EBELN = nast-objky(10).
    SELECT SINGLE ADRNR FROM LFA1 INTO ADDRNO WHERE LIFNR = VENDOR.
    TYPE-POOLS: szadr.
    DATA adr_kompl TYPE szadr_addr1_complete.
    DATA adr1 TYPE szadr_addr1_line.
    DATA adtel TYPE szadr_adtel_line.
    DATA admail TYPE szadr_adsmtp_line.
    DATA adfax TYPE szadr_adfax_line.
    CALL FUNCTION 'ADDR_GET_COMPLETE'
           EXPORTING
                addrnumber              = ADDRNO
           IMPORTING
                addr1_complete          = adr_kompl
           EXCEPTIONS
                parameter_error         = 1
                address_not_exist       = 2
                internal_error          = 3
                wrong_access_to_archive = 4
                OTHERS                  = 5.
    Mail
      LOOP AT adr_kompl-adsmtp_tab INTO admail.
        MOVE admail-adsmtp-smtp_addr TO atab-mail.
      ENDLOOP.
    if sy-subrc = 0.
      DATA: FILENAME TYPE STRING.
      CONCATENATE 'PurchaseOrder' nast-objky INTO FILENAME SEPARATED BY '-'.
      DATA: MESSAGELINE1 TYPE STRING,
            MESSAGELINE2 TYPE STRING.
    CONCATENATE 'Do you want to send ' FILENAME ' through E-mail to' into MESSAGELINE1.
    CONCATENATE atab-mail '?' into MESSAGELINE2.
      data: answer    TYPE c.
      CALL FUNCTION 'POPUP_TO_CONFIRM_STEP'
           EXPORTING
                defaultoption = 'N'
                textline1     = MESSAGELINE1
                textline2     = MESSAGELINE2
                titel         = ' '
                start_column  = 35
                start_row     = 10
           IMPORTING
                answer        = answer.
      IF answer EQ 'J' OR answer EQ 'Y'.
    Code to find Contact person
        DATA: CONTACT TYPE EVERK.
        SELECT SINGLE VERKF FROM EKKO INTO CONTACT WHERE EBELN = nast-objky(10).
    Internal Table declarations
        DATA: I_OTF TYPE ITCOO OCCURS 0 WITH HEADER LINE,
              I_TLINE TYPE TABLE OF TLINE WITH HEADER LINE,
              I_RECEIVERS TYPE TABLE OF SOMLRECI1 WITH HEADER LINE,
              I_RECORD LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
    Objects to send mail.
              I_OBJPACK LIKE SOPCKLSTI1 OCCURS 0 WITH HEADER LINE,
              I_OBJTXT LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
              I_OBJBIN LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
              I_RECLIST LIKE SOMLRECI1 OCCURS 0 WITH HEADER LINE,
    Work Area declarations
              WA_OBJHEAD TYPE SOLI_TAB,
              W_CTRLOP TYPE SSFCTRLOP,
              W_COMPOP TYPE SSFCOMPOP,
              W_RETURN TYPE SSFCRESCL,
              WA_DOC_CHNG TYPE SODOCCHGI1,
              W_DATA TYPE SODOCCHGI1,
              WA_BUFFER TYPE STRING, "To convert from 132 to 255
    Variables declarations
              V_FORM_NAME TYPE RS38L_FNAM,
              V_LEN_IN LIKE SOOD-OBJLEN,
              V_LEN_OUT LIKE SOOD-OBJLEN,
              V_LEN_OUTN TYPE I,
              V_LINES_TXT TYPE I,
              V_LINES_BIN TYPE I.
              DATA :  s_control_parameters TYPE ssfctrlop,
                      s_output_options     TYPE ssfcompop.
                      s_control_parameters-getotf = 'X'.
                      s_control_parameters-no_dialog = 'X'.
                      s_control_parameters-preview   = 'X'.
                      s_output_options-tdnoprint = 'X'.
                      s_output_options-tdimmed   = ''.
                      s_output_options-tddest = 'LP01'.        "Spool: Output device
                      s_output_options-tdreceiver = sy-uname.
                      s_output_options-tdcover = ''.
             CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
             EXPORTING
                FORMNAME = 'ZSMART_MM_003'
             IMPORTING
               FM_NAME = V_FORM_NAME
             EXCEPTIONS
               NO_FORM = 1
               NO_FUNCTION_MODULE = 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.
             W_CTRLOP-GETOTF = 'X'.
             W_CTRLOP-NO_DIALOG = 'X'.
             W_COMPOP-TDNOPREV = 'X'.
             CALL FUNCTION V_FORM_NAME
             EXPORTING
                CONTROL_PARAMETERS = s_control_parameters
                OUTPUT_OPTIONS = s_output_options
                USER_SETTINGS = ''
                nast          = nast
                WA_ADDRESS    = WA_ADDRESS
             IMPORTING
                JOB_OUTPUT_INFO = W_RETURN
             TABLES
                addtel  = it_addtel
                addsmtp = it_addsmtp
             EXCEPTIONS
                FORMATTING_ERROR = 1
                INTERNAL_ERROR = 2
                SEND_ERROR = 3
                USER_CANCELED = 4
                OTHERS = 5.
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    Convert SMartform to pdf
          I_OTF[] = W_RETURN-OTFDATA[].
          CALL FUNCTION 'CONVERT_OTF'
          EXPORTING
            FORMAT = 'PDF'
            MAX_LINEWIDTH = 132
          IMPORTING
            BIN_FILESIZE = V_LEN_IN
          TABLES
            OTF = I_OTF
            LINES = I_TLINE
          EXCEPTIONS
           ERR_MAX_LINEWIDTH = 1
           ERR_FORMAT = 2
           ERR_CONV_NOT_POSSIBLE = 3
           OTHERS = 4.
    IF SY-SUBRC <> 0.
    ENDIF.
          LOOP AT I_TLINE.
            TRANSLATE I_TLINE USING '~'.
            CONCATENATE WA_BUFFER I_TLINE INTO WA_BUFFER.
            ENDLOOP.
            TRANSLATE WA_BUFFER USING '~'.
            DO.
              I_RECORD = WA_BUFFER.
              APPEND I_RECORD.
              SHIFT WA_BUFFER LEFT BY 255 PLACES.
              IF WA_BUFFER IS INITIAL.
                EXIT.
                ENDIF.
                ENDDO.
    Attachment
                REFRESH: I_RECLIST,
                I_OBJTXT,
                I_OBJBIN,
                I_OBJPACK.
                CLEAR WA_OBJHEAD.
                I_OBJBIN[] = I_RECORD[].
    Create Message Body Title and Description
                I_OBJTXT = 'Sir, '.
                APPEND I_OBJTXT.
                I_OBJTXT = ''.
                APPEND I_OBJTXT.
                I_OBJTXT = 'Please Find Attached '.
                APPEND I_OBJTXT.
                I_OBJTXT = FILENAME.
                APPEND I_OBJTXT.
                I_OBJTXT = 'For your reference'.
                APPEND I_OBJTXT.
                I_OBJTXT = ''.
                APPEND I_OBJTXT.
                I_OBJTXT = 'Regards'.
                APPEND I_OBJTXT.
                I_OBJTXT = CONTACT.
                APPEND I_OBJTXT.
    *Mail Subject
                DESCRIBE TABLE I_OBJTXT LINES V_LINES_TXT.
                READ TABLE I_OBJTXT INDEX V_LINES_TXT.
                WA_DOC_CHNG-OBJ_NAME = 'Purchase Order'.
                WA_DOC_CHNG-EXPIRY_DAT = SY-DATUM + 10.
                WA_DOC_CHNG-OBJ_DESCR = 'Purchase Order'.
                WA_DOC_CHNG-SENSITIVTY = 'F'.
                WA_DOC_CHNG-DOC_SIZE = V_LINES_TXT * 255.
    Main Text
                CLEAR I_OBJPACK-TRANSF_BIN.
                I_OBJPACK-HEAD_START = 1.
                I_OBJPACK-HEAD_NUM = 0.
                I_OBJPACK-BODY_START = 1.
                I_OBJPACK-BODY_NUM = V_LINES_TXT.
                I_OBJPACK-DOC_TYPE = 'RAW'.
                APPEND I_OBJPACK.
    Attachment (pdf-Attachment)
                I_OBJPACK-TRANSF_BIN = 'X'.
                I_OBJPACK-HEAD_START = 1.
                I_OBJPACK-HEAD_NUM = 0.
                I_OBJPACK-BODY_START = 1.
                DESCRIBE TABLE I_OBJBIN LINES V_LINES_BIN.
                READ TABLE I_OBJBIN INDEX V_LINES_BIN.
                I_OBJPACK-DOC_SIZE = V_LINES_BIN * 255 .
                I_OBJPACK-BODY_NUM = V_LINES_BIN.
                I_OBJPACK-DOC_TYPE = 'PDF'.
                I_OBJPACK-OBJ_NAME = 'smart'.
                I_OBJPACK-OBJ_DESCR = FILENAME.
                APPEND I_OBJPACK.
                CLEAR I_RECLIST.
                I_RECLIST-RECEIVER = atab-mail.
                I_RECLIST-REC_TYPE = 'U'.
                APPEND I_RECLIST.
                CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
                EXPORTING
                  DOCUMENT_DATA = WA_DOC_CHNG
                  PUT_IN_OUTBOX = 'X'
                  COMMIT_WORK = 'X'
                TABLES
                    PACKING_LIST = I_OBJPACK
                    OBJECT_HEADER = WA_OBJHEAD
                    CONTENTS_BIN = I_OBJBIN
                    CONTENTS_TXT = I_OBJTXT
                    RECEIVERS = I_RECLIST
                EXCEPTIONS
                    TOO_MANY_RECEIVERS = 1
                    DOCUMENT_NOT_SENT = 2
                    DOCUMENT_TYPE_NOT_EXIST = 3
                    OPERATION_NO_AUTHORIZATION = 4
                    PARAMETER_ERROR = 5
                    X_ERROR = 6
                    ENQUEUE_ERROR = 7
                    OTHERS = 8.
    IF SY-SUBRC <> 0.
    WRITE:/ 'Error When Sending the File', SY-SUBRC.
    ELSE.
    WRITE:/ 'Mail sent'.
    ENDIF.
    Regards
    Nausal

  • How i can send a mail to the user SAP Office mailbox through the spool.

    hi all,
    I have created an report and scheduled for background and it generated a spool now how i can send a mail to the user SAP Office mailbox through that spool.
                          please provide me the sample code if possible.
                   thanks.

    Read the spool number with this...
        SELECT RQIDENT
        INTO (T_TSP01-RQIDENT)
        FROM TSP01
        WHERE RQOWNER EQ SY-UNAME
          AND RQCLIENT EQ SY-MANDT.
        APPEND T_TSP01.
        ENDSELECT.
    Use this FM RSPO_IRETURN_RAW_DATA to read the content of the spool into an Internal Table...
    Finally use this FM SO_OBJECT_SEND to send the mail to an SAP Office user...
    Greetings,
    Blag.

  • How to send external mails to the user

    Dears,
    How to send external mails to the user who creates the sales document (Quotation)
    Can you please suggest what modification required in the FM
    Thanks,
    pinky

    You can have a partner function like 'Created by' and use an exit to populate the User ID to this partner function(dont have the system right now but i think this can be done with standard partner detr. procedure also)
    Then, create an Output type for that Partner function with transmission medium as 'External Send'. You can use the standard SAP program to trigger the email. To send the actual email after the output is trigerred, the link connection has to be set up be BASIS but if you want to check, then goto SOST and see if the email got trigerred or not.

  • [iPad Mini 1st Gen.] Can't send E-Mails with the normal "Mail" App

    Hi,
    I can't send E-Mails with the normal E-Mail App, it works only with another Mail App, but then I can't send pictures. Maybe my new router is the cause, but it works with my iPhone 5, only with my iPad mini it doesn't work.Well, how I can solve the problem?
    Sorry for my bad English.
    Many Greetings from Germany.

    Hi,
    i can't change the iCloud SMTP Server settings for outgoing E-Mails.It isn't possible to make these "How to" (or how i can call it?) and the moves before i have already done and the issue haven't solved. I think my iPad mini is to old....
    Many greetings,
    xbdsmallwork
    Edit: I have a iCloud Mail Account.

  • Send a mail with the class CL_HTTP_CLIENT

    hi,
    i use this program and i would send a mail with a attachment file PDF. I try to use the function module SO_NEW_DOCUMENT_ATT_SEND_API1 but i dont know to translate the data XSTRING to internal table.
    Thank you.
    *& Report  ZYTEST_TRANSFER_URL2                                        *
    REPORT  zytest_transfer_url2                    .
    *- begin of internal data
    TYPE-POOLS: swfxc, icon.
    DATA: l_http_client TYPE REF TO if_http_client.
    DATA: l_url TYPE string.
    DATA: l_code TYPE sy-subrc.
    DATA: l_code_string TYPE string.
    DATA: l_message_string TYPE string.
    DATA: lt_http_fields TYPE tihttpnvp.
    DATA: l_http_field_wa TYPE ihttpnvp.
    DATA: l_char_header(40) TYPE c.
    DATA: l_body_string TYPE string.
    DATA : line TYPE string.
    DATA: result_tab TYPE TABLE OF string,
    result_str TYPE string.
    *- end of internal data
    DATA: lv_contents TYPE string.
    DATA: lv_location TYPE string.
    *- begin of parameters
    PARAMETERS: url TYPE swc_value.
    PARAMETERS : receiver TYPE somlreci1-receiver LOWER CASE.
    *- end of parameters
    START-OF-SELECTION.
      PERFORM main.
    *& Form main
    text
    FORM main.
    PERFORM get_contents USING lv_contents.
    *- Create the HTTP-Client
      l_url = url.
    l_proxy_host =
    l_proxy_service =
      CALL METHOD cl_http_client=>create_by_url
      EXPORTING
      url = l_url
    proxy_host = l_proxy_host
    proxy_service = l_proxy_service
      IMPORTING
      client = l_http_client
      EXCEPTIONS
      argument_not_found = 1
      plugin_not_active = 2
      internal_error = 3
      OTHERS = 4.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE 'S' NUMBER sy-msgno
        WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    *- send the http post
      CALL METHOD l_http_client->send
        EXCEPTIONS
          http_communication_failure = 1
          http_invalid_state         = 2.
      IF sy-subrc <> 0.
        WRITE: / icon_red_light AS ICON.
        CALL METHOD l_http_client->get_last_error
          IMPORTING
            code    = l_code
            MESSAGE = l_message_string.
        CALL METHOD l_http_client->close.
        l_code_string = l_code.
        CONCATENATE 'HTTP-Send: RC=' l_code_string              "#EC NOTEXT
        INTO l_code_string .
        CONCATENATE l_code_string l_message_string
        INTO l_message_string SEPARATED BY space.
        PERFORM print_string USING l_message_string.
        EXIT.
      ENDIF.
    *- receive the result of http post
      CALL METHOD l_http_client->receive
        EXCEPTIONS
          http_communication_failure = 1
          http_invalid_state         = 2.
      IF sy-subrc <> 0.
        WRITE: / icon_red_light AS ICON.
        CALL METHOD l_http_client->get_last_error
          IMPORTING
            code    = l_code
            MESSAGE = l_message_string.
        CALL METHOD l_http_client->close.
        l_code_string = l_code.
        CONCATENATE 'HTTP-Receive: RC=' l_code_string           "#EC NOTEXT
        INTO l_code_string .
        CONCATENATE l_code_string l_message_string
        INTO l_message_string SEPARATED BY space.
        PERFORM print_string USING l_message_string.
        EXIT.
      ENDIF.
    *- print the results
      CALL METHOD l_http_client->response->get_status
        IMPORTING
          code = l_code.
      IF l_code < 300.
    HTTP-codes: 100 - 199 = informations
    HTTP-codes: 200 - 299 = client-request successful (200 = OK)
        WRITE: / icon_green_light AS ICON.
      ELSE.
    HTTP-codes: 300 - 399 = redirected; further actions required
    HTTP-codes: 400 - 499 = client-request incomplete
    HTTP-codes: 500 - 599 = server errors
        WRITE: / icon_red_light AS ICON.
      ENDIF.
    *-- get the http header fields
      CALL METHOD l_http_client->response->get_header_fields
        CHANGING
          fields = lt_http_fields.
      LOOP AT lt_http_fields INTO l_http_field_wa.
        l_char_header = l_http_field_wa-name.
        WRITE: / l_char_header.
        l_char_header = l_http_field_wa-value.
        WRITE: l_char_header.
      ENDLOOP.
      WRITE: / sy-uline.
    *- get the body
      DATA: lv_bin_contents TYPE xstring.
      lv_bin_contents = l_http_client->response->get_data( ).
      PERFORM save_file USING lv_bin_contents.
    ENDFORM. "main
    *& Form print_string
    FORM print_string USING p_string TYPE string.
      REFRESH result_tab.
      SPLIT p_string AT cl_abap_char_utilities=>cr_lf INTO TABLE result_tab.
      LOOP AT result_tab INTO result_str.
        WRITE:/ result_str.
      ENDLOOP.
    ENDFORM. " print_string
    *& Form save_file
    text
    FORM save_file USING lv_bin_contents.
      DATA: save_file(1000) TYPE c VALUE '/tmp/test3.pdf'.
      DATA: lv_file TYPE localfile.
      DATA : g_file(80).
      g_file = url.
      DO.
        SHIFT g_file LEFT UP TO '/'.
        IF sy-subrc NE 0.
          EXIT.
        ENDIF.
        SHIFT g_file LEFT.
      ENDDO.
      SHIFT g_file RIGHT UP TO '.'.
      SHIFT g_file RIGHT.
      lv_file = save_file.
      OPEN DATASET lv_file FOR OUTPUT IN BINARY MODE.
      IF sy-subrc NE 0.
        WRITE:'SY-SUBRC :',sy-subrc.
    MESSAGE i000 WITH text-014. "'File Directory not found'.
        EXIT.
      ENDIF.
      TRANSFER lv_bin_contents TO lv_file.
      CLOSE DATASET lv_file.
      IF sy-subrc <> 0.
        EXIT.
      ENDIF.
      IF sy-subrc EQ 0.
    MESSAGE i000 WITH text-012."'Successfully downloaded to Application
    server'.
        EXIT.
      ENDIF.
    ENDFORM. "save_file

    hi,
    i use this program and i would send a mail with a attachment file PDF. I try to use the function module SO_NEW_DOCUMENT_ATT_SEND_API1 but i dont know to translate the data XSTRING to internal table.
    Thank you.
    *& Report  ZYTEST_TRANSFER_URL2                                        *
    REPORT  zytest_transfer_url2                    .
    *- begin of internal data
    TYPE-POOLS: swfxc, icon.
    DATA: l_http_client TYPE REF TO if_http_client.
    DATA: l_url TYPE string.
    DATA: l_code TYPE sy-subrc.
    DATA: l_code_string TYPE string.
    DATA: l_message_string TYPE string.
    DATA: lt_http_fields TYPE tihttpnvp.
    DATA: l_http_field_wa TYPE ihttpnvp.
    DATA: l_char_header(40) TYPE c.
    DATA: l_body_string TYPE string.
    DATA : line TYPE string.
    DATA: result_tab TYPE TABLE OF string,
    result_str TYPE string.
    *- end of internal data
    DATA: lv_contents TYPE string.
    DATA: lv_location TYPE string.
    *- begin of parameters
    PARAMETERS: url TYPE swc_value.
    PARAMETERS : receiver TYPE somlreci1-receiver LOWER CASE.
    *- end of parameters
    START-OF-SELECTION.
      PERFORM main.
    *& Form main
    text
    FORM main.
    PERFORM get_contents USING lv_contents.
    *- Create the HTTP-Client
      l_url = url.
    l_proxy_host =
    l_proxy_service =
      CALL METHOD cl_http_client=>create_by_url
      EXPORTING
      url = l_url
    proxy_host = l_proxy_host
    proxy_service = l_proxy_service
      IMPORTING
      client = l_http_client
      EXCEPTIONS
      argument_not_found = 1
      plugin_not_active = 2
      internal_error = 3
      OTHERS = 4.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE 'S' NUMBER sy-msgno
        WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    *- send the http post
      CALL METHOD l_http_client->send
        EXCEPTIONS
          http_communication_failure = 1
          http_invalid_state         = 2.
      IF sy-subrc <> 0.
        WRITE: / icon_red_light AS ICON.
        CALL METHOD l_http_client->get_last_error
          IMPORTING
            code    = l_code
            MESSAGE = l_message_string.
        CALL METHOD l_http_client->close.
        l_code_string = l_code.
        CONCATENATE 'HTTP-Send: RC=' l_code_string              "#EC NOTEXT
        INTO l_code_string .
        CONCATENATE l_code_string l_message_string
        INTO l_message_string SEPARATED BY space.
        PERFORM print_string USING l_message_string.
        EXIT.
      ENDIF.
    *- receive the result of http post
      CALL METHOD l_http_client->receive
        EXCEPTIONS
          http_communication_failure = 1
          http_invalid_state         = 2.
      IF sy-subrc <> 0.
        WRITE: / icon_red_light AS ICON.
        CALL METHOD l_http_client->get_last_error
          IMPORTING
            code    = l_code
            MESSAGE = l_message_string.
        CALL METHOD l_http_client->close.
        l_code_string = l_code.
        CONCATENATE 'HTTP-Receive: RC=' l_code_string           "#EC NOTEXT
        INTO l_code_string .
        CONCATENATE l_code_string l_message_string
        INTO l_message_string SEPARATED BY space.
        PERFORM print_string USING l_message_string.
        EXIT.
      ENDIF.
    *- print the results
      CALL METHOD l_http_client->response->get_status
        IMPORTING
          code = l_code.
      IF l_code < 300.
    HTTP-codes: 100 - 199 = informations
    HTTP-codes: 200 - 299 = client-request successful (200 = OK)
        WRITE: / icon_green_light AS ICON.
      ELSE.
    HTTP-codes: 300 - 399 = redirected; further actions required
    HTTP-codes: 400 - 499 = client-request incomplete
    HTTP-codes: 500 - 599 = server errors
        WRITE: / icon_red_light AS ICON.
      ENDIF.
    *-- get the http header fields
      CALL METHOD l_http_client->response->get_header_fields
        CHANGING
          fields = lt_http_fields.
      LOOP AT lt_http_fields INTO l_http_field_wa.
        l_char_header = l_http_field_wa-name.
        WRITE: / l_char_header.
        l_char_header = l_http_field_wa-value.
        WRITE: l_char_header.
      ENDLOOP.
      WRITE: / sy-uline.
    *- get the body
      DATA: lv_bin_contents TYPE xstring.
      lv_bin_contents = l_http_client->response->get_data( ).
      PERFORM save_file USING lv_bin_contents.
    ENDFORM. "main
    *& Form print_string
    FORM print_string USING p_string TYPE string.
      REFRESH result_tab.
      SPLIT p_string AT cl_abap_char_utilities=>cr_lf INTO TABLE result_tab.
      LOOP AT result_tab INTO result_str.
        WRITE:/ result_str.
      ENDLOOP.
    ENDFORM. " print_string
    *& Form save_file
    text
    FORM save_file USING lv_bin_contents.
      DATA: save_file(1000) TYPE c VALUE '/tmp/test3.pdf'.
      DATA: lv_file TYPE localfile.
      DATA : g_file(80).
      g_file = url.
      DO.
        SHIFT g_file LEFT UP TO '/'.
        IF sy-subrc NE 0.
          EXIT.
        ENDIF.
        SHIFT g_file LEFT.
      ENDDO.
      SHIFT g_file RIGHT UP TO '.'.
      SHIFT g_file RIGHT.
      lv_file = save_file.
      OPEN DATASET lv_file FOR OUTPUT IN BINARY MODE.
      IF sy-subrc NE 0.
        WRITE:'SY-SUBRC :',sy-subrc.
    MESSAGE i000 WITH text-014. "'File Directory not found'.
        EXIT.
      ENDIF.
      TRANSFER lv_bin_contents TO lv_file.
      CLOSE DATASET lv_file.
      IF sy-subrc <> 0.
        EXIT.
      ENDIF.
      IF sy-subrc EQ 0.
    MESSAGE i000 WITH text-012."'Successfully downloaded to Application
    server'.
        EXIT.
      ENDIF.
    ENDFORM. "save_file

  • Send a mail to the user after first time login

    How to send mail  to the user after the user login for the first time in oim 11g r2

    How to send mail  to the user after the user login for the first time in oim 11g r2

  • How to send a mail about the test plan status

    Hi
    I have finished the development of ecatt automation test cases.
    And I have integrated the ecatt  automation test cases into the test plan of TWB.
    I have scheduled a job in background to run the test plan.
    After the job has finished, I need to send a email to related users to tell them the status of each test cases in the test plan.
    Is there any way to implement it?
    Thanks a lot in advance!

    Hello,
    You can send mail with the status of the test catalog-
    specify a mail system to which Test Workbench test objects send messages to the people responsible
    Please refer the below link for more information:
    http://help.sap.com/saphelp_smehp1/helpdata/en/6a/88370a002911d2bd02080009b4534c/frameset.htm
    Regards,

  • PO output type to send a mail  to the user along with PO output as PDF file

    Hi Friends,
    I have one requirement from client.
    Client wants the PO output to be converted to PDF format and sent to User while doing the PO release through e-mail. Can anybody guide me how to Configure a New Output Type and convert the PO output into PDF and send to User through e-mail.
    Thanks
    Nazer

    This can be done with the standard form itself.
    first find out the output type u r using.
    Then goto T-code NACE and then choose EF- purchase order and then select the output type u r using.
    Then goto the 'processing Routines' at the lefe side of the screen.
    There u can find out the output forms for this output typr u r using. Here add 'Simple mail-7' in the list and then give the program name and the smartform or the script u r using.
    We can also give the mail texts for this output form.
    After that goto ME22N and then choose the 'Messages' tab and then click the simple mail and in the 'communication method' kindly provide the mail id for which the PO mail has to be sent.
    And then the mail can be viewed in the inbox of the recipient.
    in this way we can sent the PO mail to the corresponding mail address,.
    I guess this will solve ur issue.
    Thanks and Regards
    Siva
    Edited by: Sivaprakash R on Apr 20, 2009 1:00 PM
    Edited by: Sivaprakash R on Apr 20, 2009 1:00 PM

Maybe you are looking for

  • Import Manager 'Error 5611520 - Error Saving Key Mapping'

    I am using CREDITOR_EXTRACT in R/3 to send Vendor IDoc to XI and use CREMDM04 type.  XI generates an XML file that I load into MDM using a client that is set up for Inbound/Outbound.  The key mappings have been turned on for the Vendor repository. In

  • SQL Server Cursor dioe not run in Hyperion Workspace

    Hi all, I have a bqy file which runs fine in the design studio client (v9.3) however when I import it into the Workspace and try and run it i get the following error : An Interactive Reporting Service error has occurred.-SQL API: [SQLFetchScroll], SQ

  • Skip screen in BDC

    Hi All, I want to skip screen in BDC while upload data what should I do? Pleas help me in this regard. Do you think if I pass ‘/n’ it’ll work? ERFORM sub_bdc_dynpro USING 'MP002200' '2000'.   PERFORM sub_bdc_field USING :           'P0022-BEGDA'    t

  • Plant wise sale report

    Hai.. How to get plant wise sales. Please help me out by giving the Tcode. thank you, Srinivas.

  • Problem creating container for filter entity

    Hi, I have a working API gateway instance (11.1.2.1.0). But from today when I tried to access to it using my policy studio, it gives me this embarrassing error. It worked well, and the gateway instance itself is serving well. I can stop and start the