Using Microsoft Outlook to receive a report from ABAP...

Guys may you please have a look at this coding of myne, i want to send a report as an e-mail(my outlook inbox) but when i execute it nothing is happening if there is any configuration that has to be done please can anyone send me the steps to do that configuration or help out with any solution because right now i have to submit this report, please guys help out ..Any helpful information that i get i will immeditely allocate points................
Thanx a lot i know you are going to help me big time......
Kind Regards,
Fred
*& Report  Z_MAILCOPY_NEW
REPORT  Z_MAILCOPY_NEW.
*Definition of the data!!!!                                             *
Data: it_packing_list like sopcklsti1 occurs 0 with header line,
      it_contents     like solisti1 occurs 0 with header line,
      it_receivers    like somlreci1 occurs 0 with header line,
      it_attachment   like solisti1 occurs 0 with header line,
      gd_cnt type i,
      gd_sent_all(1) type c,
      gd_doc_data like sodocchgi1,
      gd_error type sy-subrc.
Data: it_message type standard table of SOLISTI1 initial size 0
      with header line.
Parameters: psubject(40) type c default 'Hello',
            p_email(40)  type c default '[email protected]'.
AT SELECTION-SCREEN.
START-OF-SELECTION.
PERFORM populate_message_table.
*Send email message, although is not sent from SAP until mail send
*program has been executed(rsconn01)
PERFORM send_email_message.
*Instructs mail send program for SAPCONNECT to send email(rsconn01)
PERFORM initiate_mail_execute_program.
*&      Form  POPULATE_MESSAGE_TABLE
      Adds text to email text table
form populate_message_table.
Append 'Email line 1' to it_message.
Append 'Email line 2' to it_message.
Append 'Email line 3' to it_message.
Append 'Email line 4' to it_message.
endform.                "POPULATE_MESSAGE_TABLE
*&      Form  SEND_EMAIL_MESSAGE
      Send email message
form send_email_message.
Fill the document data.
gd_doc_data-doc_size = 1.
Populate the subject/generic message attributes
gd_doc_data-obj_langu  = sy-langu.
gd_doc_data-obj_name   = 'z_orders_audit'.
gd_doc_data-obj_descr  = psubject.
gd_doc_data-sensitivty = 'f'.
Describe the body of the message
clear it_packing_list.
refresh it_packing_list.
it_packing_list-transf_bin = space.
it_packing_list-head_start = 1.
it_packing_list-head_num = 0.
it_packing_list-body_start = 1.
describe table it_message lines it_packing_list-body_num.
it_packing_list-doc_type = 'RAW'.
append it_packing_list.
Add the recipients email address
clear it_receivers.
refresh it_receivers.
it_receivers-receiver = p_email.
it_receivers-rec_type = 'u'.
it_receivers-com_type = 'int'.
it_receivers-notif_del = 'x'.
it_receivers-notif_ndel = 'x'.
append it_receivers.
Call the FM to post the message to SAPMAIL
call function 'SO_NEW_DOCUMENT_ATT_SEND_API1'
exporting
   document_data              = gd_doc_data
   put_in_outbox              = 'x'
importing
   sent_to_all                = gd_sent_all
tables
   packing_list               = it_packing_list
   contents_txt               = it_message
   receivers                  = it_receivers
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.
Store function module return code
gd_error = sy-subrc.
Get it_receivers return code
loop at it_receivers.
endloop.
endform.                    " SEND_EMAIL_MESSAGE
*&      Form  INITIATE_MAIL_EXECUTE_PROGRAM
      Instructs mail send program for SAPCONNECT to send email.
form initiate_mail_execute_program.
wait up to 2 seconds.
if gd_error eq 0.
submit rsconn01 with mode = 'INT'
with output = 'X'
and return.
endif.
endform.                    " INITIATE_MAIL_EXECUTE_PROGRAM

Hi Fred,
besides the configuration issue of smtp there are 2 more things that sometimes cause problems:
1. As of Basis 610 you need an explicit commit work to get mails sent out (at least if you use the business communication services where I guess your FM is internaly using those and maybe even performing the commit work).
2. The sender of the mail (i.e. the user that executes the report) needs to have a e-mail adress assigned to his user as otherwise the system cannot add a reply to adress.
Best Regards
Michael

Similar Messages

  • Receive Original Email Whenever I Reply to an Email Using Microsoft Outlook Exchange Server

    This is a problem I've seen other people post about, but I haven't found a solution.  Whenever I reply to an email using Microsoft Outlook 2007 with Exchange Server on my computer, I receive a copy of the original email (not the reply, but the original email that I replied to) on my Curve.  My BB email is set up with BIS and my carrier is Verizon, but I've seen people post about this with other carriers.
    Apparently there is some kind of incompatibility between Microsoft Exchange Server and BIS that is causing this problem.
    This is a huge pain, because everytime I reply to an email, I have to delete a copy of the original email on my blackberry. 
    Does anyone know the solution to this?

    Under "tools", "Options" , "applications" on my computer there isn't a "mailto". so these instructions don't work. Any other ideas?

  • HT204053 Every time I try to access my emails on microsoft outlook I get a message from windows that mobileme services have stopped working. windows then tries to find a solution and says mobileme is not installed correctly. When I try to repair or uninst

    Every time I try to access my emails on microsoft outlook I get a message from windows that mobileme services have stopped working. windows then tries to find a solution and says mobileme is not installed correctly. When I try to repair or uninstall via the control panel my pc cannot find the route????? I do have an iphone and ipad. What can I do?

    The CrashIDs are what is needed. Do not attempt to attach or paste the reports.
    #Run Firefox in safe mode does that prevent crashes ?<br/>[[Troubleshoot Firefox issues using Safe Mode]]
    #Disable all plugins
    #Repeat and this time try in Windows safe mode. use the F8 key <br /> http://windows.microsoft.com/en-us/windows/start-computer-safe-mode#start-computer-safe-mode=windows-7
    So you are saying it works ok as long as you avoid certain pages such as this Forum. That makes me wonder if it could be malware that is blocking access to assistance.Run malwarescans with multipe and up-to-date tools.
    Sometimes a problem with Firefox may be a result of malware installed on your computer, that you may not be aware of.
    You can try these free programs to scan for malware, which work with your existing antivirus software:
    * [http://www.microsoft.com/security/scanner/default.aspx Microsoft Safety Scanner]
    * [http://www.malwarebytes.org/products/malwarebytes_free/ MalwareBytes' Anti-Malware]
    * [http://support.kaspersky.com/faq/?qid=208283363 TDSSKiller - AntiRootkit Utility]
    * [http://www.surfright.nl/en/hitmanpro/ Hitman Pro]
    * [http://www.eset.com/us/online-scanner/ ESET Online Scanner]
    [http://windows.microsoft.com/MSE Microsoft Security Essentials] is a good permanent antivirus for Windows 7/Vista/XP if you don't already have one.
    Further information can be found in the [[Troubleshoot Firefox issues caused by malware]] article.
    Did this fix your problems? Please report back to us!

  • How can I get iCloud using Microsoft Outlook Express?

    With MobileMe I was able to import my mail, contacts, folders, etc. using Microsoft Outlook Express on a PC. I notice since moving Mobile Me to iCloud, when I try to access it using Outlook Express I receive an error saying the server rejected my password, even after verifying several times I am using the correct password. Is iCloud supported for Outlook Express?
    Thanks!

    Make sure to go into your icloud panel on your PC (in control panel) and on your phone (settings) and check everything you want to synch.  Curious to know if this works for you as mine was working perfectly until last week.

  • Can you use microsoft outlook express 6 email on a mac

    how do you use microsoft outlook express 6 email on a mac

    You cannot use Outlook Express email client on Mac OS.
    You can install Windows on Mac but it seems like overkill to get your email going.
    Can you let me know what you want to achieve?
    You should really ise Mail programwhich is native to Apple.
    TZ

  • Is it possible to flag e-mails and/or right click an e-mail to mark as read/unread, etc. when using Microsoft Outlook Web Access in Firefox on a Mac?

    Is it possible to flag e-mails and/or right click an e-mail to mark as read/unread, etc. when using Microsoft Outlook Web Access in Firefox on a Mac?
    == This happened ==
    Every time Firefox opened
    == I've never been able to figure out how to do those things in Firefox.

    When you use OWA in something other than IE, you're using OWA lite and no--it is not possible to do either in OWA lite (well, new Exchange stuff makes my answer a little less emphatic but still: pretty much no). Thanks Microsoft. But this guy made it possible to mark unread/read and select all/none:
    http://david-burger.blogspot.com/2008/07/firefox-greasemonkey-outlook-web-access_19.html

  • Paying bills online... can't complete the payment using email via TDS, but it worked when I used Microsoft Outlook as my email client???

    to pay a bill via email, I download the pdf sent to me and am prompted to enter a security code. Everything works on the form, but the adobe does not allow me to select the year 2014 to complete the payment... using my TDS email. I had been using Microsoft Outlook for my email in the past and the download worked perfectly. my utility company told me to upgrade to Adobe 7... my Adobe version is XI

    fwiw - sorta sounds like an email program problem.
    Be well...

  • I am using microsoft outlook for email in firefox. When I select the envelope for email it takes me to a mailto window in outlook which I have to close.

    I am using microsoft outlook for email on latest version of firefox. In the applications window the only selection for outlook is mailto. When I select the envelope it takes me to outlook, however the first page is a mailto page with a link to my home page. I have to close that and get to my email page. How can I skip the mailto and go right to the outlook inbox page? Thank you.

    I may have made a mistaken assumption that you were using Outlook.com (online webmail). If you are using Microsoft Office Outlook, then you actually would need an add-on to put a button for that program on the toolbar. I'm not sure if there is one specific to Outlook, but there is an extension named Custom Buttons that can be tweaked to do a wide range of things.
    * https://addons.mozilla.org/firefox/addon/custom-buttons/
    * forum for getting help with the add-on: http://custombuttons.sourceforge.net/forum/
    But... I 'm not sure it's worth the effort because you usually can switch between Firefox and Outlook pretty quickly using the Windows Task Bar or Alt+Tab (keep holding Alt after you release Tab to see all the open windows and then Tab to the one you want).

  • HT1277 i am using Microsoft outlook and i keep getting asked to rebuild why do i keep getting this i also keep losing the emails i am saving.

    i am using microsoft outlook and sometimes i keep getting asked to rebuild and i lose my emails why is this.

    Please post Outlook related questions on Microsoft's own forums for their Mac softawre as Apple Communities only provide support for Apple products:
    http://www.officeformac.com/productforums/

  • I am using Microsoft OUtlook Web Access for work email and I am losing functionality. What do I do?

    I use Microsoft Outlook Web Access for work emails when not at the office4 and I cannot/do not have any options to enlarge text or change fonts, etc. What do I need to do to make it work as if IE were my default browser?
    Thanks.

    Outlook Web App (new name) on Exchange Server 2010 should be quite full featured. The Outlook Web Access supplied with Exchange 2003 didn't offer a very good experience for browsers other than IE...
    Could you describe where the problem with fonts is: when composing messages, or when reading/working with the UI?

  • Hi,  i am using Microsoft outlook 2011, version 14.3.9 on my Mac. i use outlook for my business mails but facing problem of viruses. plz advise.

    Hi,
    I have OsX 10.9 installed and use Microsoft office for Mac 2011 for my business emails. before i not installed the antivirus as i thought MAC not get infected but my IT People always advice to install the Symantec anti virus. 2 months back out e-mail server get down as my system created too many junk E-mails (as per my IT staff).
    now i have installed Symantac antivirus and no such E-mails. still everytime i scan my system i get visuses detected in outlook datafile.
    shall appreciate your advice on the same to avoid viruses.
    Regards,
    Ali.

    Any and all viruses in your Outlook email database would be from incoming attachments. Virtually 100% of them from Windows users who forward them, or get an email virus on their end which sends out the same email to everyone in their contact list. A few randomly come in with spam, such as a fake FedEx or UPS email saying the attachment is some sort of missed delivery notice, but is actually a Windows .exe file.
    Any such email viruses do not work on the Mac OS. They can't. They require .dll files in the Windows OS, and Windows as the active OS itself to work. On your Mac, they're just a small amount of wasted disk space that can't do anything. The only way you could send them out is by forwarding an email you received with the attachment still in place.
    As such though, a lot of businesses require Mac users to have AV software to catch such attachments so you know they exist and don't forward them. Otherwise, OS X still has very little need of AV software.
    It's also not uncommon for AV software to report false positives. The viruses Symantec is detecting could be just that. Or, they still actually are on your Mac, but you can't see them. In a very odd decision, neither Entourage, or the new replacement Outlook for Mac actually delete anything from the email database, even after you remove it from the Deleted folder.
    To really clear out the database, close Outlook. Hold down the Option key and launch it again. Instead of Outlook's normal interface, you'll get this:
    Most users have only the one account, so this is likely what you'll see. Click the Rebuild button. It should only take a few seconds to run. More if your email database is large. When it's done, it will show two entries. One that again simply says "Main Identity", and another with a date after it. The one with the date is the original before rebuilding.
    Close the MS Database Utility and launch Outlook normally. If everything looks as it should (check out your contacts list and live email you expect to be there), then the rebuild worked as expected without creating errors in the newly rebuilt database. Close Outlook.
    Now go into your user account at:
    /Users/your_account/Documents/Microsoft User Data/Office 2011 Identities/
    You will find the same two folders there you saw in the utility. Main Identity, and Main Identity [date]. If you want, highlight both folders and do a Get Info (Command+I) on them and look at the size difference. If you've deleted hundreds, or thousands of emails from the Deleted folder within Outlook, especially if they were lots of attachments in them, the size difference could be huge. That difference is all of the inaccessible deleted emails that were still part of the database.
    Put the Main Identity [date] folder in the trash and delete it. Now run your AV software. Any viruses that were still part of that old database are now truly gone and won't show up in a report.

  • How can i use microsoft outlook on iPhone 4S?

    I'm wondering if I can sync microsoft outlook from my Mac computer with my iPhone 4S

    If personal email, follow the steps below:
    Settings > Mail > Add Account > Outlook.com
    If work/university/exchange email, talk with IT first, then add it via:
    Settings > Mail > Add Account > Exchange

  • Using Crystal Report to create reports from ABAP

    Hello,
    We are currently using Jetform as the designer for our outputs like Invoice, Order confirmation, etc.....
    We would like to switch to Crystal instead, but don't really know where to start from.
    - We already have crystal on our B/W instance
    - The additional need for Crystal is in R/3, and would be triggered trough ABAPs.
    What I am looking for. I guess, is the equivalent to when:
    we call up smartforms from ABAP using the generated function modules
    we call up sapscript from ABAP using the predefine function call (write_form open_form close_form, etc)
    we call up Jetform using special control code along with the data, sent to a jetform configured printer
    => What kind of call would we then make to send data to Crystal Reports place holder and print them?
    => What kind basis set-up is needed to have to comunication between Crystal and SAP established?
    Thank you in advance for yours hints

    Hi,
    You will likely be able to access the tables directly using the Opensql driver using Crystal Reports.  I don't understand why you are assuming that an Infoset is necessary.  Can you point me to the documentation that states that an Infoset is necessary?
    In any case, if you want to create an Infoset, this is done in SQ02.  You need to make sure that you belong to a user group in order for Crystal Report to see the infoset.

  • How to Use Solution Manager to collect Status Reports from Consultants

    Hi,
          I am planning to use Solution Manager for collecting the weekly status reports from my consultants and maintain it as a repository . Please let me know the best way of doing this in SOLMAN. There should be mailing options too.
    BR,
    Raj

    Hi Rajasan,
    to be able to meet this requirement, you need to set up plan working load in admin tab for your resource,  they need to update actual data based on the work completion, you will get status of work,
    if you require email, you need to set-up scot, then develop a program with execution scheduling
    please check and revert
    Anil

  • I use Microsoft outlook and want to stop getting mail into the apple mail as well

    I have always preferred the microsoft outlook program and have never enjoyed the apple mail as I can't do the things I like. Plus we also use a PC for work and we need the outlook appointments etc to merge the way we like them to.  Can I somehow stop the apple mail program for also getting all the emails? and if I can how do I clean it out without loosing and emails etc.

    Just disable all the accounts in Mail or delete them after saving your mail into .mboxes. These can be imported into Outlook.

Maybe you are looking for

  • "Mac OS X cannot be installed on this computer." New Hard Drive.

    I have just bought a new Seagate Hard Drive and I want to install Mac OS X 10.5 on it. My MacBook is from the days of Tiger, but I have since upgraded to Leopard using the upgrade discs that Apple gave out. My next door neighbor has a brand new MacBo

  • Change documents list if somone restarts the plan in IP10

    Hi all, How can i see the change documents list of IP10, I NEED TO SEE THE DETAILS IF SOMEONE HAS RESTARTED THE PLAN. Thanks Anish

  • Modify Code

    Hi Guys, I need some help please. There is a note on Payment terms. Please see the link below https://service.sap.com/sap/support/notes/1316578 Here the solution is to :- In the message class FC, change the message text for message 116 to: "When ente

  • Pass code required

    I keep getting a pass code required message on my iPad?? Is this a bug or is there a way to fix?

  • Charging iPad One vs iPad 3rd gen via USB...

    just got an iPad 3rd gen.  As I've read here, apparently, the PC's USB port doesn't supply enough power to make the 3rd gen battery charging icon say "charging".  Instead, it reads "not charging".  However, it initially DOES say 'charging', before ch