macro needs info on currently highlighted message in search folder

I created a search folder, "Messages Sent Or Received Prior To 2008)
by using the Advanced Search and creating a query. The list of
messages is shown, including just the lowest level folder name.

I can navigate through the messages, and I'd like write a macro to
show the full folder path of the currently selected (not opened)
message, because I have many dozens of folders and they're not all
named uniquely at the lowest level.

Can this be done?

Thanks
tbone
0
tbone
11/13/2009 12:14:09 AM
outlook 87535 articles. 11 followers. Follow

4 Replies
926 Views

Similar Articles

[PageSpeed] 32

Show it where? Outlook version?

-- 
Sue Mosher, Outlook MVP
   Author of Microsoft Outlook 2007 Programming:
     Jumpstart for Power Users and Administrators
    http://www.outlookcode.com/article.aspx?id=54


"tbone" <noneedto@email.me> wrote in message 
news:4o8pf5tu3g4p2e0p85gb1ng991k23nmb8e@4ax.com...
>I created a search folder, "Messages Sent Or Received Prior To 2008)
> by using the Advanced Search and creating a query. The list of
> messages is shown, including just the lowest level folder name.
>
> I can navigate through the messages, and I'd like write a macro to
> show the full folder path of the currently selected (not opened)
> message, because I have many dozens of folders and they're not all
> named uniquely at the lowest level.
>
> Can this be done?
>
> Thanks
> tbone 


0
Sue
11/13/2009 12:45:51 AM
Oops...

On Thu, 12 Nov 2009 19:45:51 -0500, "Sue Mosher [MVP]"
<suemvp@gmail.com> wrote:

>Show it where? Outlook version?

I'm using Outlook 2003. I'd like to just pop up the full path of the
parent folder in a msgbox.

BTW, love the book! It inspired me to be a programmin' fool the last
few days. I've done a lot of VBA in Excel but hardly any in Outlook
until now.

Thx
tbone
0
tbone
11/13/2009 1:08:23 AM
I don't have your earlier post. (Please, please quote earlier posts so
people using newsreader software can follow the conversation.) But if I
remember correctly, you'd use something like this:

    MsgBox Application.ActiveExplorer.Selection(1).FolderPath

FYI, there is a newsgroup specifically for general Outlook programming 
issues "down the hall" at microsoft.public.outlook.program_vba or, via web 
interface, at 
http://www.microsoft.com/office/community/en-us/default.mspx?dg=microsoft.public.outlook.program_vba
-- 
Sue Mosher, Outlook MVP
   Author of Microsoft Outlook 2007 Programming:
     Jumpstart for Power Users and Administrators
    http://www.outlookcode.com/article.aspx?id=54


"tbone" <noneedto@email.me> wrote in message
news:j2cpf5heqohg678qlastvpof39kr0acirb@4ax.com...
> Oops...
>
> On Thu, 12 Nov 2009 19:45:51 -0500, "Sue Mosher [MVP]"
> <suemvp@gmail.com> wrote:
>
>>Show it where? Outlook version?
>
> I'm using Outlook 2003. I'd like to just pop up the full path of the
> parent folder in a msgbox.
>
> BTW, love the book! It inspired me to be a programmin' fool the last
> few days. I've done a lot of VBA in Excel but hardly any in Outlook
> until now.
>
> Thx
> tbone



0
Sue
11/13/2009 3:03:13 AM
On Thu, 12 Nov 2009 22:03:13 -0500, "Sue Mosher [MVP]"
<suemvp@gmail.com> wrote:

>I don't have your earlier post. (Please, please quote earlier posts so
>people using newsreader software can follow the conversation.) But if I
>remember correctly, you'd use something like this:
>
>    MsgBox Application.ActiveExplorer.Selection(1).FolderPath
>
>FYI, there is a newsgroup specifically for general Outlook programming 
>issues "down the hall" at microsoft.public.outlook.program_vba or, via web 
>interface, at 
>http://www.microsoft.com/office/community/en-us/default.mspx?dg=microsoft.public.outlook.program_vba

Sue,

1. Thanks very much for continuing to visit the group; I'm glad to see
you're still willing to spend time with Outlook.

2. I'm so used to using Agent, which saves and threads everything for
me, that I didn't recognize that some people might not always have the
prior messages available. I will do the "quote and <snip>" thing in
the future (because I really think having to scroll down 400 lines to
see replies is a lot worse than top-posting).

3. For some reason, I didn't see the Outlook VBA group on my news
server originally. Thanks for pointing that out; I refreshed and am
now subscribed to a few more Outlook groups.

4. Your memory serves you very well. Not only was that exactly what I
was looking for, but your solution works perfectly!

Thank you very much!
tbone
0
tbone
11/13/2009 7:51:53 PM
Reply:

Similar Artilces:

macro needed
hello listers to begin with i have no great excel skills what I am looking for is a macro that I can easily use to send mail to a list of users I have made a web page that students sign up on http://biosciences.utoledo.edu/prs enter there info when they press submit the data is saved to a text file that can be opened as a csv file in excel I would like to have a macro go row by row down the page and extract the email from column G and insert that in to an email and also the students name from coulmn B. The csv file is set up like this ID Fname Lname StudentID TransmitID Section e...

Need VB code to edit cell values
I need some VB to do the following please (My VB is not good enough yet) Starting from the active cell (call it the StartCell) In the cell to the left.. ThreeChars = Value.right(3) (the last three chars) Value = Value - last three characters (assume value is text & at least 3 chars present) In StartCell.. value = ThreeChars (as text, overwrite any contents of StartCell) move active cell one down from StartCell Examples of before/after -- Don Guillett Microsoft MVP Excel SalesAid Software dguillett@gmail.com "Stephen Ford" <Stephen_Ford_no@spam_uwclub....

Search for a text in a cell and give the outcome later
Dear expert, C30 to C60 contains some data. Say I wan to find piano and use =MATCH("*piano*",C30:C60,0) in cell D31 It gives me the anwer 20 in D31. 20 is the squence of piano. How can I use the function and use return the the whole cell content which is "Play Piano"? I only know where it is. How to locate where and give the whole content in D32 please? Thanks Elton Play games Play golf Play guitar Play piano Play Kite Play Sccoer Play cards Play WII Play music =INDEX(C30:C60,D31) -- Regards! Stefi „Elton Law” ezt írta: &g...

.pst folder help
How do I put a .pst folder in My Documents for constant up to date copying? Mine seems to be in a folder called Office Data File which I cannot open but do not see any pst file...can someone kindly help me out here? Thanks! Right click the pst in outlook and select properties and then click Advanced You will see the location of the file. Depending on your view settings it may be hidden. Close the pst, (right click it, close) Move the file to the location you desire. Open Outlook select File - Open - Outlook Data File Browse to the file and select it. OK Done Regards Mark Dormer &quo...

Calendar/address book: sharing folder with only 1 .PST for n users
I'm going to share a folder on my file server for ten specific users where I create unique .PST file. For example I create test.pst and I assign full rights to this one for my 10 users. For every client, can I link MS Outlook to test.pst ? In this way I could use ONLY sharing calendar and Address book ? I'm not interesting to use mailbox on this pst, because for mailboxes I can use local pst for each machine. "Riccardo" <ric.castellani@alice.it> wrote in message news:990c53ca-cae4-4146-ace7-fec4287c7771@m73g2000hsh.googlegroups.com... > I'm going to share a fo...

Message Filtering on MS Outlook 2000
Hi I'm Leo I have a problen on my MS Outlook Message Filtering, this is the scenario. User A sends a message to User B (inside my organisation) and User C (outside) then the message goes to User B Inbox, then User C replies to User B and the message goes to Junk Folder. This is not usually heppening when User C sends Email on User B, normally it goes to User B inbox. We have a Rule that filters the Email Address of the sender so I think that the MS Outlook filters the message thats why it goes to Junk Folder. My question is how did MS Outlook filters messages even if we do not have Rul...

My OL 2000 will not open-get error message
I have MS Office Premium-all of the other programs work. When I try to open OL2000 I get the the error msg. MS Outlook has encountered a problem and needs to close. I removed MS Office Premium and re-installed it-same problem. I also clicked repair from Control Panel-same problem. -- Roma Does it work correctly when trying to start Outlook in Safe Mode? Start-> Run; outlook.exe /safe For additional troubleshooting steps see; http://www.howto-outlook.com/faq/outlookdoesntstart.htm -- Robert Sparnaaij [MVP-Outlook] Coauthor, Configuring Microsoft Outlook 2003 http://www...

Two search category & two search terms
Hello friend Using excel 2003. I have one excel file & in sheet1 i have lot of data. Data record as per below column a1 : is header 1 to h1: is header 8 column a2 : application code column b2 : partno column c2 : description column d2 : remark column e2 : qty Right now i have search only one base category & one search terms. i.e. search category : select header3 & search term : piston. Actually i required two category & two search terms. For example: If In first search category if i have select "Header 1" & enter in search term : "02.2...

Help with macro to choose printer
Hi, I am new to macros in Excel and this is what I did to print a worksheet: ------------------------------------------------------------------------ Range("A1:W35").Select ActiveSheet.PageSetup.PrintArea = "$A$1:$W$35" Selection.PrintOut From:=1, To:=1, Copies:=1, Collate:=True End Sub ------------------------------------------------------------------------ Works great except that I want to select the printer to use and the macro won't stop at the point to choose printer. Any way to work around this? Any help is greatly appreciated. Emilio Emilio,this wil...

HTML is being converted to text in outlook messages
I have a mixed environment of Exchange 2k3 SP2, and Exchange 5.5 SP4. Currently, the Ex5.5 server is acting as the bridgehead, so all inbound/outbound mail passes through the IMC on that box. My problem is with HTML content within emails. I recieve the messages ok (they are displayed as HTML), but when I forward them, the email loses the HTML content, and displays it in plain text. I have checked the "HTML" box setting in the IMC on the Ex5.5 bridghead server. Is there anywhere else that this needs to be enabled? Any help is appreciated. On Thu, 9 Mar 2006 09:20:31 -080...

duplicate messages #3
Each time I click "send/receive", the same two email messages are sent to my inbox. If i clik three times, the two messages will drop into my inbox for a total of six messages! Understand, i do not have "save messages on the server" selected. I have uninstalled and reinstalled outlook twice with to no avail? Suggestions? Happens to me too. My ISP said it is poorly written spam that fails to complete sending properly, so Outlook times out without completing the task of downloading including recognising what has already been downloaded and what has not. Why can&#...

Message Tracking Center not functioning
The Message Tracking Center has been working fine for many months, however today I tried to use it and received the error message: "The tracking database on SERVER_NAME is not available or the message has left the Exchange organization. Facility: Microsoft Exchange Management ID no: c1032751 Microsoft Exchange Management I've tried turning tracking off and on under the ESM server properties. I've tried changing the folder location (I hopes it reset something). The permissions on the SERVER_NAME.log folder appear to be open for Administrators. Also looking at the tracking ...

rule to move sent mail to 2nd mailbox sent folder
We have Outlook 2002 (enterprise). I have my own mail box and in addition, another shared mailbox. What I need to be able to do is have a rule set up so that when I reply to an email from the shared mail box, that shows the from email address as ''my name and 'on behalf of; 'shared mail box'' it moves the sent email from my own personal email to the sent mail folder on the shared email folder. I also need to set up a rule for any emails that are deleted from the shared email box are put into the 'shared email delete box'. I have looked at the rules and can&#...

Highlighting Operating Hours
I have an XY scatter plot of temperature inside an office building throughout different times of day across a 3 week period. What I would like to see are coloured bars that highlight when the office is open (operating hours). I tried adding colour-filled rectangles with 50% transparency, but I am having printing issues. It looks fine on screen, but when I go to print the bars are scaled differently than the chart thus they don't line up properly. I think this might be a bug in Excel. This issue comes and goes; sometimes it prints OK, most of the time it doesn't (and I haven&#...

Restoring Public folders to another server
We have a server that has crashed and AD is all up the wop. It was our exchange server (Exchange 2000). We have a new server in place but we can't restore our public folders from backup (Veritas 9.1). Is there a way to restore public folders to a different server or do we have to rebuild the server with all the same names etc.....? In advance thankyou for the help. -- Network Consultant a full recovery server is your only option, unless you go with a 3rd party tool... "pete" <pete@discussions.microsoft.com> wrote in message news:0DCA3555-EA66-4BCC-AB7C-59896AB02...

Need a code
I need a code that does the following: If C3>D3, B3 value will start blink and if C3<D3, E3 value will start blink. Any help please. Thanks in advance. Personally, I would recommend against blinking text, but if you insist on employing it, this website should help you get started... http://www.cpearson.com/Excel/BlinkingText.aspx NOTE: Pay particular attention to the second of the two points delineated in the Summary section at the bottom of the webpage. -- Rick (MVP - Excel) "MAX" <MAX@discussions.microsoft.com> wrote in message news:C7E6...

troubles with graphs and VBA macros...
Hello, I'm having troubles with creating some graphs with an Excel VBA Macro. I would like to create about 35 graphs from a set of data stored in a unique datasheet. As the set of data can change (length, numbers, etc ..) I created a macro to generate the graph starting from a template graph. The macro runs correctly a few times but after a variable number of graph (from 5 to 15, it depends on the weather), it crashes with : Run-Time Error '-2147417848 (80010108)' : Methode 'XValues' of object 'series' failed If i go in debug mode and repeat the error, I get :...

Unable to run excel macro after changing file name
After changing the filename in an excel macro, receiving Error number 5 - Invalid procedure call or argument when users with excel 2000 run the macro. Users with excel 2003 are not having this issue Post the line of code that is causing the error. -- Cordially, Chip Pearson Microsoft MVP - Excel Pearson Software Consulting, LLC www.cpearson.com "merf" <merf@discussions.microsoft.com> wrote in message news:F68DF323-214D-4F01-8D8E-654F9500242E@microsoft.com... > After changing the filename in an excel macro, receiving Error > number 5 - > Invalid procedure cal...

Outlook Connector 12.1
I have installed Outlook Connector 12.1 (12.0.6423) in Outlook 2003. I was able to download all the email messages from my Hotmail account into Outlook, but several of them have severely truncated subject lines, while others do not. Also, several of these messages have excessive extra line breaks, even when the window states "Extra line breaks in this message were removed." I cannot find a pattern to this. The subject lines and line breaks are complete and normal when viewed via Hotmail. I tried the 'repair Outlook Connector' feature via "Control Panel...

Experts Needed for Color Coding
Hello: this ought to be a challenge. I have a spreadsheet with 10 columns Col A contains an ID There are various color coded cells in each; Row 1: B - C are red; F is yellow Row 2: C is green; E is yellow, etc. Row count could be up to 300 Objective: Before refreshing this report (from Access query) 1. identify cell color for cells in rows 2. After refresh, find row (per the ID field) and replicate the color Conditions: New unique rows may be added during the refresh; these will not be color coded The color is applied without consistent rules in many cases Rather than refreshing the repo...

Search for userform or procedure name?
Tried to search XL files in Windoze Explorer for userform, procedure and module names - doesn't work. Does anyone know of a search tool that can do this? Sure would be handy! Thanks in advance. Check out MZ-Tools for VBA. It's an add-in at... http://www.mztools.com/v3/mztools3.aspx -- Hope this helps. If it does, please click the Yes button. Thanks in advance for your feedback. Gary Brown "salgud" wrote: > Tried to search XL files in Windoze Explorer for userform, procedure and > module names - doesn't work. Does anyone know of a search too...

Posting to Public Folder-VIEW--the FROM field
When I post to a public folder, and click VIEW--the FROM field is grayed out. This worked in Outlook 2000. Are there any work-arounds? ...

Grabbing Info from a TextBox on a Report
We want to add a TextBox to a report that is viewed online. The data collected in this TextBox will be used to adjust the report filter. We want to allow our users to enter as much of a Customer Name as they want after they see the report with all Customers shown. We then want to use this info to change the Report Filter. We have never tried this before. For some reason, we cannot see the data in the TextBox in our VBA code. It appears that Access Reports behave differently than Access Forms as far as grabbing data from TextBoxes. We must be missing something. Does a...

Need help backing up OL2002 items (or folders)
HELP says: "If you want to create a folder to which you can drag items for safekeeping or to distribute to another computer. Create a new data file (.pst) and drag items to it. If you used the default name for the folder when you created the data file, the folder will be called Personal Folders . In the Folder List (Folder List: Displays the folders available in your mailbox. To view subfolders, click the plus sign (+) next to the folder. If the Folder List is not visible, on the View menu, click Folder List.), drag any item from your current folders to the new folder. Press CTRL...

NEed report of income and expenses broken down
I'm using Microsoft Money 2006 and I entered all of my checking account transactions for last year and categorized everything. Now I need a report of the income and of the expenses broken down by category, with the transactions listed. If I go to reports, all I can get is a pie chart or bar chart. I need a printed report with numbers to give to the accountant tomorrow. I was able to export a report to a spreadsheet, but all it did was show the total expenses in each category. What I need is a report showing the categories for income and for expenses, list the transactions in each ca...