Try to send mail  , not working  , why ?

hello  ,
i try to use function SO_NEW_DOCUMENT_ATT_SEND_API1.
in my program it is not working so i found note ( 609696 )  with examle
also not working  , i check in "scot" nothing show up  .
what can be the reason  ?
sap example
*& Report  ZSSO_DOCUMENT_SEND_API1
*&  Send document with OTF/ALI attachment from spool to external reci-
*&  pient. OTF/ALI document is converted to PDF/HTML format during the
*&  SAPconnect send process.
*&  This report serves as example documentation for the function
*&  modules SO_NEW_DOCUMENT_ATT_SEND_API1 and SO_DOCUMENT_SEND_API1.
*&  Following this example you should be able to develop your own
*&  report to send documents with all kinds of attachments.
REPORT   ZSSO_DOCUMENT_SEND_API1.
Data Declaration
  Data: docdata    like sodocchgi1,
        objpack    like sopcklsti1 occurs  1 with header line,
        objhead    like solisti1   occurs  1 with header line,
        objtxt     like solisti1   occurs 10 with header line,
        objbin     like solisti1   occurs 10 with header line,
        reclist    like somlreci1  occurs  1 with header line.
  Data: listobject like abaplist   occurs  1 with header line.
  Data: tab_lines  type i,
        doc_size   type i,
        att_type   like SOODK-OBJTP.
NOTE: Create ALI/OTF Document in Spool
  ALI Document can be created by displaying a list and selecting
  menue System -> List -> Print (only put to Spool).
  OTF Document can be created running report SF_EXAMPLE_01 in system.
Example used here:
  create list in memory
    submit SHOWCOLO exporting list to memory and return.
  and read list from memory into table
    CALL FUNCTION 'LIST_FROM_MEMORY'
      TABLES
        listobject       = listobject
      EXCEPTIONS
        OTHERS           = 1
    IF sy-subrc <> 0.
      message ID '61' TYPE 'E' NUMBER '731'
      with 'LIST_FROM_MEMORY'.
    ENDIF.
  Because listobject is of size RAW(1000)
      and objbin     is of size CHAR(255) we make this table copy
    CALL FUNCTION 'TABLE_COMPRESS'
    IMPORTING
      COMPRESSED_SIZE       =
      TABLES
        IN                    = listobject
        OUT                   = objbin
      EXCEPTIONS
        OTHERS                = 1
    if sy-subrc <> 0.
      message ID '61' TYPE 'E' NUMBER '731'
      with 'TABLE_COMPRESS'.
    endif.
NOTE: Creation of attachment is finished yet.
  For your report, the attachment should be placed into table
    objtxt for plain text or
    objbin for binary content.
  Now create the message and send the document.
Create Message Body
  Title and Description
    docdata-obj_name  = 'TEST_ALI'.
    docdata-obj_descr = 'Test including ALI/HTML Attachment'.
  Main Text
    objtxt = 'Test Document.'.
    append objtxt.
    objtxt = 'You will find an ALI/HTML attachment in this message.'.
    append objtxt.
    objtxt = 'Have a nice day.'.
    append objtxt.
  Write Packing List (Main)
    describe table objtxt lines tab_lines.
    read     table objtxt index tab_lines.
    docdata-doc_size = ( tab_lines - 1 ) * 255 + strlen( objtxt ).
    clear objpack-transf_bin.
    objpack-head_start = 1.
    objpack-head_num   = 0.
    objpack-body_start = 1.
    objpack-body_num   = tab_lines.
    objpack-doc_type   = 'RAW'.
    append objpack.
Create Message Attachment
  Write Packing List (Attachment)
    att_type = 'ALI'.
    describe table objbin lines tab_lines.
    read     table objbin index tab_lines.
    objpack-doc_size = ( tab_lines - 1 ) * 255 + strlen( objbin ).
    objpack-transf_bin = 'X'.
    objpack-head_start = 1.
    objpack-head_num   = 0.
    objpack-body_start = 1.
    objpack-body_num   = tab_lines.
    objpack-doc_type   = att_type.
    objpack-obj_name   = 'ATTACHMENT'.
    objpack-obj_descr  = 'Attached Document'.
    append objpack.
Create receiver list
  reclist-receiver = '[email protected]'.  "<-- change address
  reclist-rec_type = 'U'.
  append reclist.
  reclist-receiver = sy-uname.                "<-- change internal user
  reclist-rec_type = 'B'.
  append reclist.
Send Message
  CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
    EXPORTING
      document_data                    = docdata
      PUT_IN_OUTBOX                    = 'X'
  IMPORTING
    SENT_TO_ALL                      =
    NEW_OBJECT_ID                    =
    tables
      packing_list                     = objpack
      OBJECT_HEADER                    = objhead
      CONTENTS_BIN                     = objbin
      CONTENTS_TXT                     = objtxt
    OBJECT_PARA                      =
    OBJECT_PARB                      =
      receivers                        = 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.
    message ID 'SO' TYPE 'S' NUMBER '023'
            with docdata-obj_name.
  ENDIF.
write: / 'End of Program'.

Hi,
your program has problem in creating the reciever list.
check the Amit's Code in this thread. It is perfect.you can update accordingly.
Mail with attachment.
Regards,
Amit
Reward all helpful replies.

Similar Messages

  • Why does sending mail not work?

    Sending mail has stopped working. Error message says can not connect to server. I am connected thru wi-fi.

    iOS: Unable to send or receive email
    http://support.apple.com/kb/TS3899
    Can’t Send Emails on iPad – Troubleshooting Steps
    http://ipadhelp.com/ipad-help/ipad-cant-send-emails-troubleshooting-steps/
    Setting up and troubleshooting Mail
    http://www.apple.com/support/ipad/assistant/mail/
    Server does not allow relaying email error, fix
    http://appletoolbox.com/2012/01/server-does-not-allow-relaying-email-error-fix/
    Why Does My iPad Say "Cannot Connect to Server"?
    http://www.ehow.co.uk/info_8693415_ipad-say-cannot-connect-server.html
    iOS: 'Mailbox Locked', account is in use on another device, or prompt to re-enter POP3 password
    http://support.apple.com/kb/ts2621
    iPad Mail
    http://www.apple.com/support/ipad/mail/
    Try this first - Reset the iPad by holding down on the Sleep and Home buttons at the same time for about 10-15 seconds until the Apple Logo appears - ignore the red slider - let go of the buttons. (This is equivalent to rebooting your computer.)
    Or this - Delete the account in Mail and then set it up again. Settings->Mail, Contacts, Calendars -> Accounts   Tap on the Account, then on the red button that says Remove Account.
     Cheers, Tom

  • Send mail not working in MINISAP

    Hi experts,
    I did automatic workflow customizing in SWU3, then created a test workflow to send mail notification to  workflow initiator. After running WF, the mail is not received in user workplace. In workflow log it shows Mail has send.
    Did any additional configuration has to be done in SWU3....

    Hi RK
    It may have a very simple error
    - Check your work flow log with the help of SWUD .
    - Check your agent assignment
    - Check your event linkage
    Do tell me in otherwise case.
    Regards
    Sachin

  • Send mail not working

    Hi,
    My installation of APEX is not sending e-mails properly. Sometimes sends e-mails properly but must of them get lost anywhere and are not sent. There are no mails to process in APEX mail queue.
    I've tried with APEX_SENDMAIL and with UTL_SMTP but both of them give the same problem. I suspect this could be any problem with grants...
    I am using APEX 3.1.0 under Oracle XE and Ubuntu 7.04 Linux. My APEX email Instance configuration is:
    SMTP Host address: 127.0.0.1
    SMTP port: 25
    and both emails are two existing email accounts.
    Any help will be appreciated!
    Josep

    Hi Josep
    Are you 110% sure that 127.0.0.1 is the correct address of your SMTP server?
    Also, can you get your server/network administrator to confirm that Relay Permissions (if needed) have been granted to your APEX server. This may be needed in order for your SMTP to accept emails for onward transmission.
    Kind regards
    Simon

  • Why does Adobe sendnow work and the newest and greatest Adobe Send does not work?

    Why does Adobe sendnow work and the newest and greatest Adobe Send does not work? I wasted about 8 hours on trying to get Adobe Send to upload 269 files that amounted to 469MB. When it did not work I made a zip file and after a lot of wasted run time that did not work. The first situation gives little indication of when a file is loaded compared to Adobe SendNow. In both cases with Send it failed with a message like only the first 50 can be loaded. When I went and looked none of them had been loaded. With the zip file (I wanted to hide the individual files so they would not be counted) it appeared to work but very slowly and finally said it was done and I went and looked and it had done anything for oever 2 hours except a false "I'm runninng" indication.
    Thus, I took a chance with Adobe SendNow and it works great. It never gave me a limit on the amount of files nor on the size of the complete job. It shows me one file at a time when it has finished with the file uploading it. SendNow has never given me any problems.
    Why woiuld you want to change the program from SendNow to Send without the newest program being the best, fastest, user friendly program of the two? It just doesn't make sense to me. I suggest that Adobe keep SendNow working until Send is fixed. I would also suggest that SendNow and how it looks be kept, called Send, then modify Send one thing at a time until you get it to the point you need it to be for Acrobat. I have heard nothing good and now I have experienced it that Send is a piece of junk. I wasted most of my work day on giving Adobe the benefit of the doubt to find out I made a very bad decision to trust Adobe to make good decisions on the transfer of a function to another place .... both Adobe's responsibility.without making it painless for your customers that totally rely on you. Don't throw away customer confidence as it is very hard to get it back.

    Funny how you answer to "troll". (What's your handle on AT&T forums?)
    Yep! Verizon living up to it's contractual obligations by not releasing updates. Caveat emptor!
    I think there are some reasonable expectations here to keep customer's happy. When one carrier offers upgrades there is an expectation the same will happen across all the carriers. We have seen that except Big Red.
    Verizon could have said the update is in MS court months ago and stilled the voice of the disgruntled, or at least redirected it, but instead chose to be silent. Not for market share but for partial blame I think.
    We will have to agree to disagree since you only see Terms & Conditions and I, see customer satisfaction.

  • Why does the mail not work when i updated my 5s to iOs 8?

    why does the mail not work when i updated my 5s to iOs 8?

    Thank you for the reply. But can you tell me what this configuration is about and how I should do this?

  • ICloud mail not working. I can send but cannot receive. Is the system down?

    iCloud mail not working. I can send but cannot receive. Is the system down?

    Same here. I can send mails from iCloud.com Webmail, but cannot receive.
    A message that you sent could not be delivered to one or more of
    its recipients. This is a permanent error. The following address
    failed:
    "[email protected]":
    SMTP error from remote server after RCPT command:
    host: mx1.icloud.com.akadns.net
    5.1.1 unknown or illegal alias: [email protected]
    On iOS 6 device I can't receive, neither send mails.
    https://dl.dropbox.com/u/2234051/IMG_0001.PNG
    However, if I change to @me.com, everything works fine.

  • HT204053 Using I cloud my address book/ contacts are different. When I try to send mail typing in a name does not recognize it

    iCloud help, my contacts- address book are different &amp;when I try to send mail by typing in a name it is not recognized

    Make sure your default contacts account is set to iCloud. To change this go to settings > mail, calendars, contacts > default account and choose iCloud.

  • Email notification mail not working in case of customer repository

    Hi Experts,
    We have the system MDM 7.1 SP06, we are not able to get the email notification for customer repository. For other repositories like material & vendor mails are working fine. I Have checked the following steps.
    1) Added notification step to the workflow between processes.
    2) Verified the email addresses of the workflow owner and the receiver of the notification.
    3) Verified that the mds.ini has the "MailServer=" setup to the right smtp.
    I have check in workflow history, it is showing notify step but not showing details of mail like send to, mail body. While in case of material repository, it was showing complete details like send to, mail body & all.
    Previously mails for customers were working fine. Kindly suggest the solution.
    Regards,
    Gaurang

    Hi Gaurang,
    Are the time parameter same for all the repositories?
    Create a dummy user and dummy workflow,and try to send mail from that workflow.
    If this works with some id then check with the Admin id which you are using.
    This way you can eliminate the possibility of id not working.Also it will tell you that user is corrupt or not.
    Check for log and traces,kindly provide with the post here.
    Thanks,
    Ravi

  • Mail not working since visiting US

    I went to Miami this year and took my macbook with me.
    Since returning I can collect email on my Yahoo.co.uk account but I cannot send mail. I was not aware anything was changed and indeed all looks well in the accounts.
    Any idea what I need to do?

    +fix it+
    Seriously - without additional information no one can assist you
    Have you contacted Yahoo?
    Have you looked at the Yahoo FAQs?
    How are you accessing your yahoo.co.uk account?
    what happens when you try to send mail?
    What changed from the time it worked until it failed?
    What other details are there that might let someone assist you?
    Larry Nebel

  • Office 2010 MUI in Finnish and Save and Send function not working after upgrading to Lync 2013 MUI

    Problem is as follows. Used to have Office 2010, Outlook 2010 and Lync 2010, everything was working. People used it in Finnish and seemly quite a many of them used the Talleta ja lähetä (Save and Send in Finnish) in Office products.
    After upgrading Lync to 2013 version, with Finnish language pack installed with it, the Save and send does not work in Office 2010 if it is used with Finnish as display language. When you try to use it you get a Mapi error and reason is undefined or something,
    hard to say what it is exactly in english as the error message is in finnish. On those machines if the display language is changed back to english the Save and send works as it should.
    Any ideas? 

    The problem was caused by the Language Packs for Lync 2013 or Office 2013. Without them all works.
    And if you want to just unisntall the 2013 lang packs, then you also need to repair install the office 2010 ones to make it work again.

  • Apple Mail not working after internet outage.

    10.9.5 Mail not working after internet outage.  Connection doctor shows everything green.  Other apps connecting to internet fine.   Mailboxes show online.  I can login and get mail via web iCloud.com.  But Mail app will not send or receive.  Tried rebooting Mac, and restarting Mail.  Tried Rebuild.  Second day with this problem.

    Troubleshooting Apple Mail
    Troubleshooting sending and receiving email messages
    Troubleshooting sending email messages

  • HT2731 i already make my apple id but it not working why?

    sir i make id but not working why?

    What happens when you try to use it ? When you create an account you should get a email which you will need to open and click on the 'verify now' link in it.
    If it's a different problem ... ?

  • Problem with RoadRunner:  RECEIVE is ok, but SENDING does not work

    Apple Mail not working properly: Receive - OK, Send - not working
    If anyone has encountered this problem, and found a fix, please let me hear from you. Until then, I have to use the web-based email for RoadRunner.
    In a nutshell, I can receive mail, but I cannot send mail.

    Mail->Preferences->SMTP->Edit outgoing mail server list and reenter the data. I have no issues w/RR's pop server account.

  • The Restriction option to NOT ALLOW CHANGES to Mobile or Cellular data does not work why is this ?

    The Restriction option to NOT ALLOW CHANGES to Mobile or Cellular data does not work why is this ?

    Hi there,
    You may want to try force closing all open apps and resetting the device as an initial troubleshooting step. Take a look at the articles below for more information.
    iOS: Force an app to close
    http://support.apple.com/kb/ht5137
    Turn your iOS device off and on (restart) and reset
    http://support.apple.com/kb/ht1430
    Additionally, you may want to try completely disabling and re-enabling restrictions.
    -Griff W.

Maybe you are looking for

  • How to add url in iCal

    Hello, I am doing programming cocoa application.I add task in iCal.But i want to add url in task from code.I try task.url= @"gjgjh" but it is not done. Thank you...

  • Using a Windows formatted iPod Nano (4th Gen) with Bootcamp on a Mac(Win XP

    Hey I was wondering if anyone knows if you can use a previously formatted iPod Nano (4th Gen) with a Mac that has XP Bootcamped on to it. If the Nano is placed in manually manage music with the original computer it was formatted with, will it be able

  • Error AAPO169 when performing MIGO on a PO with Acc.*** Category A

    Hi, When perfoming MIGO on a PO with: - Account assignement category                      A (Asset) - Item Category in Purchasing Document          L (Subcontracting) - Single account assignement - Derive from Account assignement category    I receiv

  • Duplicate photo's in Revel and Elements after upgrade to Elements 12

    I subscribed to Revel in Nov. 2013 and used my Windows Elemennts 11 app to upload all my photos.  I recently upgraded to Elements 12 and linked it to my Revel account.  This resulted in complete duplication of every image both in Revel and in my Elem

  • Preventive maint reports

    Dear all I have the requirement is preventive maintenance reports Here they needs Equipment, Operations, Remarks, Cheked By , reason not attended the problems, Abnormal if any, actual time This thing i have communicated to follow thro IW 39 to enter