How do you tie SAP e-mail to Outlook e-mail

hai.....
how to send SAP mails to MS Outlook....
which one is better SAP MAPI or SAP Exchange Connector to integrate  SAP System with Microsoft Exchange Server???
Thanks....

hi,
chk this code.
FUNCTION zsend_mail_attachment.
""Local interface:
*"  IMPORTING
*"     REFERENCE(V_FILE_PATH) TYPE  STRING OPTIONAL
*"     REFERENCE(V_SUBJECT) TYPE  SO_OBJ_DES
*"  TABLES
*"      IT_RECEIVERS STRUCTURE  SOMLRECI1
*"      IT_MESSAGE STRUCTURE  SOLISTI1
  DATA: gd_cnt TYPE i,
        gd_sent_all(1) TYPE c,
        gd_doc_data LIKE sodocchgi1,
        gd_error TYPE sy-subrc.
  DATA objbin LIKE solisti1 OCCURS 0 WITH HEADER LINE.
  DATA : it_packing_list LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE.
Binary store for File
  DATA : BEGIN OF it_file OCCURS 0,
           row(255),
         END OF it_file.
splitting of the filepath
  DATA : BEGIN OF i_split OCCURS 0,
           row(50),
         END OF i_split.
  DATA tab_lines LIKE sy-tabix.
  REFRESH : it_file, objbin, it_packing_list, i_split.
  CLEAR   : it_file, objbin, it_packing_list, i_split.
  DESCRIBE TABLE it_message LINES tab_lines.
  READ     TABLE it_message INDEX tab_lines.
  gd_doc_data-doc_size = ( tab_lines - 1 ) * 255 + STRLEN( it_message ).
  gd_doc_data-obj_langu  = sy-langu.
  gd_doc_data-obj_name   = 'SENDFILE'.
  gd_doc_data-obj_descr  = v_subject.
  gd_doc_data-sensitivty = 'O'.
  CLEAR it_packing_list.
  it_packing_list-head_start = 1.
  it_packing_list-head_num   = 0.
  it_packing_list-body_start = 1.
  it_packing_list-doc_type   = 'RAW'.
  it_packing_list-body_num   = tab_lines.
  APPEND it_packing_list.
  IF v_file_path IS NOT INITIAL.
    DATA : v_len      TYPE i,
           v_index    LIKE sy-index,
           v_doc_type TYPE  so_obj_tp,
           v_filename TYPE  so_obj_des .
    v_len = STRLEN( v_file_path ) - 3.
    v_doc_type = v_file_path+v_len(3) .
    TRANSLATE v_doc_type TO UPPER CASE .
    SPLIT v_file_path AT '\' INTO TABLE i_split .
    DESCRIBE TABLE i_split LINES v_index .
    READ TABLE i_split INDEX v_index .
    v_filename = i_split-row .
    v_len = STRLEN( v_filename ) - 4.
    v_filename = v_filename(v_len) .
    CALL FUNCTION 'GUI_UPLOAD'
      EXPORTING
        filename = v_file_path
        filetype = 'BIN'
      TABLES
        data_tab = it_file.
    LOOP AT it_file.
      MOVE it_file-row TO objbin-line.
      APPEND objbin.
    ENDLOOP.
    CLEAR it_packing_list.
    DESCRIBE TABLE objbin LINES tab_lines.
    it_packing_list-transf_bin = 'X'.
    it_packing_list-head_start = 1.
    it_packing_list-head_num   = 1.
    it_packing_list-body_start = 1.
    it_packing_list-doc_type   = v_doc_type.
    it_packing_list-body_num   = tab_lines.
    it_packing_list-doc_size   = tab_lines * 255.
    it_packing_list-obj_descr  = v_filename.
    APPEND it_packing_list.
  ENDIF.
it_receivers-receiver = '[email protected]'.
it_receivers-rec_type = 'U'.
it_receivers-com_type = 'INT'.
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
     <b> put_in_outbox = 'X'</b>
      commit_work   = 'X'
  IMPORTING
    sent_to_all = gd_sent_all
    TABLES
      packing_list = it_packing_list
      contents_txt = it_message
      contents_bin = objbin
      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.
ENDFUNCTION.
Pl. Reward points if u find answer suitable.
rgds
anver

Similar Messages

  • How can you remove your e-mail on your profile? (Apple Support)

    How can you remove your e-mail on your profile? (Apple Support)

    I don't think you can remove your email.  If you are concerned about privacy make sure you have it set so that you are the only one who can view it. You do this under the privacy settings under Your Stuff - Profile  " If you want to change your email you can go here to make changes.
    laverne's mom

  • How do you create folders in mail app? Is there a way in 3GS IOS 5?

    How do you create folders in mail app? Is there a way in 3GS IOS 5?

    Russell D wrote:
    This is very disappointing, and i find it hard to believe that Apple would do this intentionally. It worked on previous versions of email application. Apple please don't dishonor the image of Steve Jobs this way. Fix this right away. I can't think of anything more basic than being able to organize the email that you download into folders. This absolutely ***** ... What a stinker.....
    I can't think of anything more idiotic than invoking the memory of Jobs here. Are you truly unaware that the iPad and iOS is pretty much exactly the way he wanted it to be, just like about everything else Apple?
    As to your claim of "previous email applications", certainly none in iOS ever did that, and the only folders you can create and manipulate in POP accounts are those local to only that single machine or platform, not particularly helpful or desirable in today's environments.

  • How do you move emails in Mail (5.3) to a flash drive so that it appears as it does in Mail my MacBook OS 7.5?

    How do you move emails in Mail (5.3) to a flash drive so that it appears as it does in Mail my MacBook OS 7.5?

    Can you explain in more detail what it is you want to do? I'm not clear how moving messages to a flash drive would make them appear as they do under Lion.
    Matt

  • How do you sync Windows Live Mail Calender with iPhone 4 Calender?

    How do you sync Windows Live Mail Calender with iPhone 4 Calender?

    Hey donfrombig spring,
    Thanks for the question. To setup your Live account on your iPhone, see this article:
    iOS: Setting up Hotmail, Outlook, Live, or MSN email accounts
    http://support.apple.com/kb/HT1694
    Thanks,
    Matt M.

  • How do you turn your outgoing mail server to online vs offline?

    How do you turn your outgoing mail server to online vs offline

    I had this problem too but I fixed it today. I have been unable to send emails with two of my 4 accounts.
    Go to the mail menu preferences.
    Click on account in question.
    Select the outgoing SMTP mail server (the one offline), this has a drop down list, click on the edit server list.
    Click on the advanced button.
    Make sure use default port is checked.
    Make sure SSL is unchecked (unless your provider requires it, mine does not work with it checked).
    Have authentication set to password.
    User name should be your email address for that account.
    Make sure correct password is entered (for some strange reason my password box was blank on this account).
    Push the ok button.
    For me the SSL box was checked and the password was missing. This is strange to me considering I have unchecked the SSL Box on the mail preference advance page. Also, I went through the complete set up account when I first created the account, why was my outgoing server password box empty?
    I hope this helps.
    Here is a link to some visual aids with the steps from my ISP
    http://support.knology.net/content/smtpauth/smtpredirect.cfm

  • How can you alphabetise folders in mail?

    How do you put folders in Mail (Version 5.1 (1251/1251.1)) in alphabetical order? It shouldn't be this difficult... I'm using OS X 10.7.2

    A less labour intensive way???

  • How Can you get your hot mail.

    How can I use mail on my Mac to get my hot mail like i did with outlook on my PC.?
    Mac Minni   Mac OS X (10.4.7)  

    Hello,
    If you want to use MSN / Hotmail with Apple's mail, check out the program HTTPMail Plugin at:
    http://www.automagic-software.com/downloads.php
    You can also download it from SourceForge:
    http://sourceforge.net/projects/httpmail-plugin
    And, strangely, while both the developer's site and SourceForge lists the latest version as 1.47 - Tiger release 2005-11-25, I found a 1.48 release at:
    http://mac.softpedia.com/get/Internet-Utilities/httpmail-plugin.shtml
    And also:
    http://www.macupdate.com/info.php/id/10842
    And also:
    http://www.versiontracker.com/dyn/moreinfo/macosx/18189
    I just downloaded the 1.48 version, and it is in-fact a 1.48 release. So, that would appear to be the most current version. Perhaps the normal / direct sites just haven't been updated yet.
    You can see a screen-shot and brief description of the older 1.46 version at:
    http://www.apple.com/downloads/macosx/email_chat/danielshttpmailplugin.html
    The 1.47 version of the httpmail plug-in was released in November of 2005. But, the 1.48 version was apparently released in March of 2006.
    It is not a "universal binary". It is a PowerPC only program / plug-in.
    This is not an issue if you are using a PowerPC Mac. You can just install it and use it.
    As for Intel Macs, it will install, but not run in a Intel Native program.
    If you want to use a PowerPC plug-in with Mail on an Intel Mac, then you have to set Mail to run in PowerPC mode through Rosetta.
    That will enable the plug-in to work. But, that means running mail through Rosetta which may be slower.
    Just to be safe, you might actually want to set mail to run in Rosetta before you install the plug-in. That would probably be the safest route.
    Here's a document about forcing a program to run in Rosetta.
    http://docs.info.apple.com/article.html?artnum=303120
    Give this a try and see if it works for you.
    Hope this helps.

  • How do you get Mountain Lion Mail to show sent email size?

    I upgraded to mountain lion I think a couple months ago so I don't remember exactly when I lost this feature, but in Snow Leopard for sure there was an option that when composing a new email, a little bar across the bottom of the email showed the size of your email so when you were adding attachments you could see the size your email was getting to be. I obviously haven't used that in a while because I ahvent' sent attachments in a long while, but I have recently started to do that again and tonight when I was adding files, there was no bar across the bottom of the email at all so I have no idea what size my email was. Even when I hit send and the progress bar in the bottom left of Mail ("Mail Activity") that use to show the file size right underneath the bar also now no longer shows the size so I have absolutely no idea how big the email I sent was.
    Can anyone tell me how to get the option back to show the email size of the mail your composing in that little bar on the bottom of your email as well as the file size to display as you are sending in "Mail Actiivity" window? Thanks so much if anyone can help. Thank you!

    The Apple Support Communities are an international user to user technical support forum. As a man from Mexico, Spanish is my native tongue. I do not speak English very well, however, I do write in English with the aid of the Mac OS X spelling and grammar checks. I also live in a culture perhaps very very different from your own. When offering advice in the ASC, my comments are not meant to be anything more than helpful and certainly not to be taken as insults.
    Do you have active firewall or anti-virus software?Disable it.
    Does your ISP cap or throttle your downloads?

  • How can you set up a mail group

    I want to set up different mail groups how do you do that

    While the pad guide suggests you can do it within contacts on your computer, then sync the groups to the pad, i have never been able to get that to work.  There are a couple of apps that do a good job, specifically mail shop, and whT i think is the best, group e mail.   Group e mail also allows for some attachments, which is also a benefit not in the normal mail app.  Take a look in the app store, and read the reviews to find the one you want.

  • How do you make all outgoing mail on iPhone come from one default address?

    I have multiple Apple devices which include laptop, iPad, iPhone 4, iPhone 4s.  I use several email accounts for my business.  How do you make the default outgoing email address one the iPhones one email address like you can on the laptop?  I want the outgoing email address to be the same on all devices.

    Thank you.  I think I got it for the 4 but not for the 4S.  In mail, contacts, calendars, do you choose default account?  Also, there does not appear to be a choice like this for the icloud.  How do you change the default on it?  The best I can see is icloud to account to advanced to mail to icloud account information.  On that screen there is a box that says allow sending from and the only choices you have are the icloud account and me account.  I do not see how to add another account if that is the right section.  I don't want the icloud or the me to be a return address.
    Thanks in advance.

  • How do you prioritize messages in Mail 1.3.11

    Hi,
    We use Mail 1.3.11. How do you do you mark a message to be sent as high priority in Mail?
    Thanks-Sheri

    Hello, Sheri -
    You might give this a try. (I haven't used it.)
    Mail Priority
    Good luck
    srb

  • How do you delete multiple e mail at one time

    How do you delete multiple emails at one time?

    The link works OK for me on my iMac running Safari and Tiger 10.4.11. It also works on my iPad running Mercury and iCab.
    You may be right about the trick no longer working. I have only used it once or twice and that was just as an experiment. I will quit posting the link now if it no longer works.
    This no longer works?????
    From Destef_12
    You actually can:
    it took me weeks of research to figure out finally how to decode this yet another secretive secrets of apple. there is a perfect way of deleting ALL emails at once without jailbreaking your iphone or ipad...and here it is:
    Open Inbox>>EDIT >> check/select the top message, it will highlight the move button >>press and hold the move button and uncheck the message that you had checked earlier >> lift all your fingers off from the ipad screen and leave it alone. wait until all your messages pile up on the right hand portion of the screen (in ipad). iphone will give you the actual number of emails it has selected for the action. now they are just waiting for your command to be moved ALL at once. >> choose trash to delete all of them or any other folder where u want to move them, like one piece. remember this will replicate your action on the server so u will ACTUALLY move them or delete them on the server and not just the ipad.
    once you have moved all messages to trash you can either leave them there for the scheduled cleaning or empty it right away by doing this: go to trash folder and click edit. the delete all button shows up at the bottom of the screen. hit it! you r done!
    if you do not see effects of your actions on the server make sure you have enabled Your email accounts for such actions.
    tips:
    1. please give enough time (could take upto several minutes depending the number of emails to be moved) for the emails to be selected for the move. your screen will become unresponsive while all emails are being packaged. once emails are ready, in ipad, you will see them zoomed out on the right hand side of the screen, and in iphone you will see the message showing you the actual number of messages that have been selected.
    2. avoid purging very large number of emails, the mail app might freeze or crash. if your inbox has thousands of emails change your sync settings in mail settings to fill lesser number of emails in you inbox
    Message was edited by: Demo

  • Apple Mail - how do you send to a mailing list of a hundred or more names?

    Apple Mail - how do you send to a large mailing list. I have tried pasting in a string of addresses to an Addressbook listing, copying that into BCC, but the program just chugs away for ever and then fails.
    Thanks

    Are you using iCloud? Here are the maximum numbers for sending emails:
    http://support.apple.com/kb/HT4863
    If you are referring to a different provider, check with them - every ISP has limits (to deter spammers mostly).

  • How do you mass delete e-mails on i phone 5?

    How do I mass delete e-mails in an i phone 5?

    You cannot delete all the emails in the Inbox in one operation. You can do this in the Trash.

Maybe you are looking for

  • Is there any way to write-enable an NTFS-format WD external Hard Drive ?

    I have a WD Elements external HD unit, 1TB previously formatted NTFS under Windows XP on a PC. I would like to use this HD unit to both read and write data using both the Windows PC and a MacBook Pro. But when connected to the MacBook Pro (USB), the

  • Trying to open a file from an older version to a new version of indesign

    I'm on am mac and i am trying to open a file from the 2014 indesign with 2015 software, i am getting this error: what i don't understand is why a newer version can't read the file of an older version

  • [HW Problem] Some numbers and left and right keys are not working

    Numbers one, two, three, four, eight, nine, zero, left, down, and right arrow keys constantly stop and start working. This also happens in the BIOS. I have to remove the keyboard, the hdd, and do a reboot to get them working. Device: Dell Inspiron 11

  • How to buy imac 27 inch and ship it to iraq ?

    hi im ali jalal from iraq and i want to buy imac 27 inch from apple online store and ship it to iraq is there any way to do that ? cuz i cant see my country in the list thanks

  • HP laptop with 52" LCD TV

    I have this 52" lcd tv and am toying with the thought of using it as a monitor with my laptop. Has anyone tried this setup, and if you did, does it funtion well. Thanks HP P2-1117BC x64 G460 HP dv7-1247cl X64 AMD 72 Windows 7 Home Premium AVIRA &Wind