PC Review


Reply
Thread Tools Rate Thread

StampDate Format For Data and Time

 
 
srm
Guest
Posts: n/a
 
      7th Jun 2005
I'm using the following code to insert the date and time into my
contacts notes. Is there a way to customize the format of the date
and/or time to maybe show only the date? It currently comes out as
"6/7/2005 5:09:27 PM"

I am new to coding, so answers may be such that I need to learn more
before making these changes.

Sub StampDate()
Item.Body = Now() & vbCrLf & vbCrLf & Item.Body
End Sub

Sub CommandButton1_Click()
Call StampDate()
End Sub

thanks

 
Reply With Quote
 
 
 
 
Patricia Cardoza [Outlook MVP]
Guest
Posts: n/a
 
      8th Jun 2005
Try just Date() rather than Now().

--
Patricia Cardoza
Outlook MVP
Author - Special Edition Using Microsoft Office Outlook 2003
Lead Author - Access 2003 VBA Programmer's Reference
Author - Absolute Beginner's Guide to Microsoft OneNote 2003

http://blogs.officezealot.com/cardoza
http://www.cardozasolutions.com

"srm" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> I'm using the following code to insert the date and time into my
> contacts notes. Is there a way to customize the format of the date
> and/or time to maybe show only the date? It currently comes out as
> "6/7/2005 5:09:27 PM"
>
> I am new to coding, so answers may be such that I need to learn more
> before making these changes.
>
> Sub StampDate()
> Item.Body = Now() & vbCrLf & vbCrLf & Item.Body
> End Sub
>
> Sub CommandButton1_Click()
> Call StampDate()
> End Sub
>
> thanks
>



 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Format Table data type for time Frank Microsoft Access Database Table Design 2 20th Apr 2009 07:51 PM
Need help to refine StampDate sub =?Utf-8?B?U0Nyb3dsZXk=?= Microsoft Outlook Form Programming 2 21st Sep 2007 08:08 PM
Convert data into proper time format sandip.dhamapurkar@gmail.com Microsoft Excel Worksheet Functions 1 25th Apr 2006 08:39 PM
Data Form and Time Format Jeremy Dillberg Microsoft Excel Misc 0 26th Nov 2003 09:11 PM
import data time format Steve Microsoft Excel Programming 2 28th Sep 2003 04:40 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:47 PM.