Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 13
Default Outlook express email reader

Hi Everyone,
I think of a macro which will be able to read all my email messages
and check for a specific string in any message and copy the 'from'
address to the excel sheet. I use Outlook express as the default email
program. I have obtained the following code from a website, but it
works only on Outlook. Anybody help me to do the same in outlook
express. Please also tell me which references i would have to include
in VB editor. Thanks in advance.

Sub GetFromInbox()

Dim olApp As Outlook.Application
Dim olNs As NameSpace
Dim Fldr As MAPIFolder
Dim olMail As Variant
Dim i As Integer

Set olApp = New Outlook.Application
Set olNs = olApp.GetNamespace("MAPI")
Set Fldr = olNs.GetDefaultFolder(olFolderInbox)
i = 1

For Each olMail In Fldr.Items
If InStr(olMail.Body, "ozark") 0 Or _
InStr(olMail.Subject, "ozark") 0 Then

ActiveSheet.Cells(i, 1).Value = olMail.ReceivedTime
i = i + 1
End If
Next olMail

Set Fldr = Nothing
Set olNs = Nothing
Set olApp = Nothing

End Sub

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,253
Default Outlook express email reader


you cant automate OutlookExpress with VBA

--
keepITcool
| www.XLsupport.com | keepITcool chello nl | amsterdam


RosH wrote :

Hi Everyone,
I think of a macro which will be able to read all my email messages
and check for a specific string in any message and copy the 'from'
address to the excel sheet. I use Outlook express as the default
email program. I have obtained the following code from a website,
but it works only on Outlook. Anybody help me to do the same in
outlook express. Please also tell me which references i would have
to include in VB editor. Thanks in advance.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
outlook express email question Gary Keramidas[_4_] Excel Programming 5 September 25th 05 02:15 PM
Email from Excel with Outlook Express SURESH Excel Programming 3 September 10th 05 12:20 PM
Email Macro with Outlook Express Moe Excel Discussion (Misc queries) 2 August 10th 05 02:50 PM
Can reciept of an email in outlook express be used to trigger an even in excell Jeff Excel Programming 0 September 15th 04 12:04 AM
sending email from excel using outlook express Sam Excel Programming 2 August 28th 04 11:09 PM


All times are GMT +1. The time now is 12:42 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"