View Single Post
  #1  
Old September 18th 07, 09:12 PM posted to microsoft.public.outlook.program_forms
SCrowley
external usenet poster
 
Posts: 3
Default Need help to refine StampDate sub

I have searched the Web, Discussion Groups, Outlookcode.com and have found
most of my answer; however, I need help refining.

Outlook 2007 all service packs are up to date, Custom Contact Form

I found Sue Mosher's code for Sub StampDate() *see below, which Stamps the
date and user into the Notes field. Perfect! except I need stamp to appear in
the "Last Author" field from Field Chooser (I can't find the proper name for
it, may be ModifiedBy?)

Sue's Function

Item_Write
Item.BillingInformation = Application.Session.CurrentUser

might be the answer but I don't know where to write it. I tried the
Properties/Validation tab of the "Last Author" field and tried to write the
formula in the box but Item_Write is not an option.

I don't know which code to use or how to combine them to make them work.

Any ideas for this?

*Sub StampDate()
Dim objOL As Outlook.Application
Dim objNS As Outlook.NameSpace
Dim objItem As Object
Dim strStamp As String
On Error Resume Next
Set objOL = Application
Set objItem = objOL.ActiveInspector.CurrentItem
If Not objItem Is Nothing Then
Set objNS = objOL.Session
strStamp = Now & " - " & objNS.CurrentUser.Name
objItem.Body = objItem.Body & vbCrLf & strStamp
End If
Set objOL = Nothing
Set objNS = Nothing
Set objItem = Nothing
End Sub
--
Thank you,

scrowley(AT)littleonline.com
Ads