Name of Field that registers date and time of last change?

K

Kristian

Hi,
Could anyone please help me with the name of the field
that registers date and time of the latest change in a
form?
I thought it was LastModificationTime but I get an error
message stating "it's not supported".

Having a non-English Outlook-version really is a pain in
the butt: I choose the field from the Filed Chooser with
the Swedish name but can't see the English name I need
when I want to read that field from code...

Hoping for help,
Kristian
 
K

Kristian Karre

I have a function; EditPost(rst, itm)
that "synchronizes" all the edits to a database.
It takes two parameters:
rst is a DAO recordset (Access database) and
itm is the open Contact item

Inside that function I use this code inside a
With rst - End With construct:

If itm.LastModificationTime <> "" And _ itm.LastModificationTime <>
#1/1/4501# Then _
And itm.LastModificationTime <> None Then
.LastUpdated = itm.LastModificationTime
'.LastUpdated = Now 'I tried this as well...
Else
.LastUpdated = Null
End If

If I try to assign another date value to .LastUpdated it works, but I
can't get it to work from this field.
Is it the wrong Date format or what?

Grateful for any help,
Kristian
 
S

Sue Mosher [MVP]

Use just this expression, not <> "" or <> None, to check whether the item has a value other than what the user sees as "None"

itm.LastModificationTime <> #1/1/4501#

Instead of assigning LastUpdate a value of Null, you should assign it a value of #1/1/4501#.

The newsgroup interface at Developersdex (http://www.developersdex.com) does not automatically quote the text of the original message when you post a reply. Please take the time to quote the original message manually so that people reading your current response can understand what you're talking about. Otherwise, you may not receive the answer you're looking for.

--
Sue Mosher, Outlook MVP
Outlook and Exchange solutions at http://www.slipstick.com
Author of
Microsoft Outlook Programming: Jumpstart
for Administrators, Power Users, and Developers
http://www.slipstick.com/books/jumpstart.htm
 
K

Kristian Karre

Thanks 4 input, but
1) I didn't understand the part about answers not being quoted
automatically - I get a whole list where every reply is nicely formatted
and separated from the others.
How am I to quote those?
2) My form still won't take the value from my LastModificationTime field
via the DAO recordset field into the Access database field.
The Access field is of Date/Time type with no specific format, no input
mask, no validation formula.
The recordset lets me change all other field values, so it sholud be
correct.
The Immediate Window in the debugger tells me that the
LastModificationTime field has the correct value...
And yet?!


Getting desperate...
Kristian
 

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