![]() |
If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
In your VBA editor, display the Object Browser (F2), choose VBA from the top
dropdown box and select the Strings class from the left pane. There are a variety of text functions you can use (especially InStr, Replace, Left, Mid, etc.) that can help you find certain text in the message body. Once you get the text you need, it's easy to create a new appointment item: Dim olApp As Outlook.Application Dim objAppt As Outlook.AppointmentItem Set olApp = Outlook.Application 'Create appointment item Set objAppt = olApp.CreateItem(olAppointmentItem) objAppt.Body = "My body text" -- Eric Legault (Outlook MVP, MCDBA, MCTS: Messaging & Collaboration) Try Picture Attachments Wizard for Outlook: http://www.collaborativeinnovations.ca Blog: http://blogs.officezealot.com/legault/ "StoltHD" wrote: I get confirmation for work via e-mail and want to automaticelly create an appointment item from the mail. How can I get vba to read only a bit of the text in the subjectfield to get the right mail... the subjectfield always contain 3 words in the beginning that are the same for all i.e. "Confirmation from Company" + an address then I want to get the time and hour from a textstring in the body and also the address from another textstring in the body i.e. different lines. in addition I want all text exept for the 3 first lines of the mailbody to occur as bodytext in the appointment... somebody that can help? |
Ads |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Cannot Create New Data File | Bill Byrnes | Outlook - General Queries | 0 | June 14th 06 03:19 AM |
Create shortcut for File-Open-Outlook Data | larjo42 | Outlook and VBA | 0 | May 23rd 06 03:34 PM |
How do I add an item that isn't an appointment? | smags | Outlook - Calandaring | 1 | March 22nd 06 07:35 PM |
Can't double click to create a new appointment in Outlook | pts66 | Outlook - Calandaring | 1 | March 2nd 06 07:43 PM |
Create a new item | jim | Add-ins for Outlook | 3 | February 8th 06 03:16 PM |