Populating Dates via VBA

Hemish

Registered User.
Local time
Today, 10:15
Joined
Jan 20, 2005
Messages
65
Hi,

I just need some help regarding populating a table called tblDates using VBA code.

I just want to populated fields with adding in dates from 01/01/2005 to 31/12/2009.

The fields I want to populate are
Date Month Year Day Wk_Commence MonthID Week_Nu
31/12/2005 December 2005 Saturday 26/12/2005 12 52
01/01/2006 January 2006 Sunday 26/12/2005 1 1
02/01/2006 January 2006 Monday 02/01/2006 1 1
03/01/2006 January 2006 Tuesday 02/01/2006 1 1
04/01/2006 January 2006 Wednesday 02/01/2006 1 1
05/01/2006 January 2006 Thursday 02/01/2006 1 1
06/01/2006 January 2006 Friday 02/01/2006 1 1
07/01/2006 January 2006 Saturday 02/01/2006 1 1
08/01/2006 January 2006 Sunday 02/01/2006 1 1


Thanks for your help in advanced
 
Hi,

I just need some help regarding populating a table called tblDates using VBA code.

I just want to populated fields with adding in dates from 01/01/2005 to 31/12/2009.

The fields I want to populate are
Date Month Year Day Wk_Commence MonthID Week_Nu
31/12/2005 December 2005 Saturday 26/12/2005 12 52
01/01/2006 January 2006 Sunday 26/12/2005 1 1
02/01/2006 January 2006 Monday 02/01/2006 1 1
03/01/2006 January 2006 Tuesday 02/01/2006 1 1
04/01/2006 January 2006 Wednesday 02/01/2006 1 1
05/01/2006 January 2006 Thursday 02/01/2006 1 1
06/01/2006 January 2006 Friday 02/01/2006 1 1
07/01/2006 January 2006 Saturday 02/01/2006 1 1
08/01/2006 January 2006 Sunday 02/01/2006 1 1


Thanks for your help in advanced

Look as ms access functions

Date, DateSerial, Day, Month, Datepart
Weekday, WeekDayName

http://msdn2.microsoft.com/en-us/library/aa263405(VS.60).aspx
 
Hi,

I just need some help regarding populating a table called tblDates using VBA code.

I just want to populated fields with adding in dates from 01/01/2005 to 31/12/2009.

The fields I want to populate are
Date Month Year Day Wk_Commence MonthID Week_Nu
31/12/2005 December 2005 Saturday 26/12/2005 12 52
01/01/2006 January 2006 Sunday 26/12/2005 1 1
02/01/2006 January 2006 Monday 02/01/2006 1 1
03/01/2006 January 2006 Tuesday 02/01/2006 1 1
04/01/2006 January 2006 Wednesday 02/01/2006 1 1
05/01/2006 January 2006 Thursday 02/01/2006 1 1
06/01/2006 January 2006 Friday 02/01/2006 1 1
07/01/2006 January 2006 Saturday 02/01/2006 1 1
08/01/2006 January 2006 Sunday 02/01/2006 1 1


Thanks for your help in advanced

The question has to be why you need to do this?
 

Users who are viewing this thread

Back
Top Bottom