A Microsoft Outlook email forum. Outlook Banter

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.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Clear name cache with VBA



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old September 19th 06, 05:41 PM posted to microsoft.public.outlook.program_vba
jonYCP
external usenet poster
 
Posts: 2
Default Clear name cache with VBA

Is it possible to clear the name cache from the .pst using VBA?
Ads
  #2  
Old September 19th 06, 07:33 PM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Clear name cache with VBA

If you mean the "nickname" list it's stored in the file system as an .NK2
file. It's not in the mail store.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"jonYCP" wrote in message
...
Is it possible to clear the name cache from the .pst using VBA?


  #3  
Old September 19th 06, 08:06 PM posted to microsoft.public.outlook.program_vba
jonYCP
external usenet poster
 
Posts: 2
Default Clear name cache with VBA

Thank you. Pardon my ignorance. I was referring to the name cache (as it is
referred to in various help files) that is used to Autocomplete email
addresses in the To: block of a new message. I found a reference on
Microsoft Top 10 Tips for Outlook to delete the .nk2 file to delete the
cache. This works, so that the list of emails does not appear when entering
a previously sent email address.

Actually, would you know how to ask the path to the .NK2 file from within a
VBA procedure? I am running a procedure from Access to modify Outlook data.



"Ken Slovak - [MVP - Outlook]" wrote:

If you mean the "nickname" list it's stored in the file system as an .NK2
file. It's not in the mail store.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"jonYCP" wrote in message
...
Is it possible to clear the name cache from the .pst using VBA?



  #4  
Old September 20th 06, 01:00 AM posted to microsoft.public.outlook.program_vba
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 5,848
Default Clear name cache with VBA

The path is C:\Documents and Settings\windows logon\Application
Data\Microsoft\Outlook\profile_name.nk2.

You can query the Win32 API call SHGetFolderPath to get the path to
\Application Data. From there you can concatenate the rest of the name up to
the profile name. The usage for SHGetFolderPath is in the MSDN library.

The profile name is the hard part. You'd have to use Extended MAPI and
IOlkAccountManager using C++ or Delphi. For VBA/VB you would need to use the
Redemption.RDOSession.ProfileName property. Redemption is a 3rd party
library at www.dimastr.com/redemption

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"jonYCP" wrote in message
...
Thank you. Pardon my ignorance. I was referring to the name cache (as it
is
referred to in various help files) that is used to Autocomplete email
addresses in the To: block of a new message. I found a reference on
Microsoft Top 10 Tips for Outlook to delete the .nk2 file to delete the
cache. This works, so that the list of emails does not appear when
entering
a previously sent email address.

Actually, would you know how to ask the path to the .NK2 file from within
a
VBA procedure? I am running a procedure from Access to modify Outlook
data.


 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Couldn't open user defined form and clear cache Lucia Outlook and VBA 3 September 6th 06 11:48 AM
How do I clear autocomplete cache when I have no NK2-file? Kjetil Thorstensen Outlook - Using Contacts 3 August 29th 06 11:03 PM
How do you clear an appointmnet kept? RonPasa Outlook - Using Contacts 3 July 29th 06 06:53 AM
Macro to clear Outlook cache [email protected] Outlook - Using Forms 0 May 29th 06 07:28 PM
Clear "To" cache. William Stacey [MVP] Outlook - General Queries 2 March 14th 06 06:45 PM


All times are GMT +1. The time now is 07:05 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.