Solved

Read Through Email Subject Line?

Posted on 2008-10-03
2
532 Views
Last Modified: 2012-05-07
I have this script that I received from an Expert here at EE.  It worked as I asked, but user needs some additional information.  In the snippet below, "Missing Transactions" is a folder that contains emails.  Would it be possible for me to diplay the Subject Line of the emails within that folder? (Missing Transactions)

Also, does anyone know of a good reference book for scripting in general?

Thanks
SnowLapa
Const olFolderInbox = 6

 

Set objOutlook = CreateObject("Outlook.Application")

Set objNamespace = objOutlook.GetNamespace("MAPI")

Set objFolder = objNamespace.GetDefaultFolder(olFolderInbox):Set objFolder= objFolder.Parent

Set flds = objFolder.folders

Set mpfSubFolder = flds.GetFirst

 

 

Do While Not mpfSubFolder Is Nothing

	If mpfSubFolder.Name = "IS Department" Then

		Set colItems = mpfSubFolder.folders

		For Each objItem in colItems

    		if objItem.name = "Missing Transactions" then

    			'DO WHATEVER

    		End If

		Next

    End If

    Set mpfSubFolder = flds.GetNext

Loop

Open in new window

0
Comment
Question by:SnowLapa
2 Comments
 
LVL 5

Accepted Solution

by:
lodar123 earned 125 total points
ID: 22638293
hey.. me again :)
try to modify that part of the script with this....
 

Set colItems = mpfSubFolder.folders

For Each objItem in colItems

	if objItem.name = "Missing Transactions" then

    		Set colItems2 = objItem.items

		For Each objItem2 in colItems2

    			if objItem2.Subject = "SUBJECT" then

    				'DO WHATEVER

			End If

		Next

	'DO WHATEVER

	end If

Next

Open in new window

0
 

Author Closing Comment

by:SnowLapa
ID: 31623588
Worked great.

Thanks
SnowLapa
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to writing scripts for a Client/Server computing environment it is essential to consider some way of enabling the authentication functionality within a script. This sort of consideration mainly comes into the picture when we are dealin…
Deploying a Microsoft Access application in a Citrix environment is not difficult but takes a few steps. However, Citrix system people are often of little help, as they typically know next to nothing about Access. The script provided here will take …
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now