VBA code to show today's date + a sequencial number in subject lin

N

NotACoder

Hello,
I have created a .oft template in Outlook 2003.
I need a VBA code, to display today's date + a sequenyial number, in the
subject line when user uses that template to send me a message. Example:

Case # 1111091 or if it it the 12th email using that template it will be
11110912.

Thank you
 
M

Michael Bauer [MVP - Outlook]

You might use the NewInspector event where you need to identify whether the
new item is your template or not (maybe by the Subject). Then add to the
Subject whatever you want to.

For the number you could store the current value in a text file. Here are
examples for how to read/write a file:

http://www.vboffice.net/sample.html?mnu=1&lang=en&smp=14&cmd=showitem

--
Best regards
Michael Bauer - MVP Outlook

: Outlook Categories? Category Manager Is Your Tool
: VBOffice Reporter for Data Analysis & Reporting
: <http://www.vboffice.net/product.html?pub=6&lang=en>


Am Wed, 11 Nov 2009 08:00:01 -0800 schrieb NotACoder:
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top