I am new with VBA programming. I have designed one form in which there is a button. After clicking this button I want to insert record in my table having one date column. Th
You can create a table containing every possible day number
[DayOfMonth]
dd
--
1
2
3
...
30
31
and then just use a query like this to generate one row for each day in the current month
SELECT DateSerial(Year(Date()), Month(Date()), dd) AS IDate
FROM DayOfMonth
WHERE Month(DateSerial(Year(Date()), Month(Date()), dd)) = Month(Date())
To use it as an INSERT query would be
INSERT INTO tbl_ShipOrders (IDate)
SELECT DateSerial(Year(Date()), Month(Date()), dd) AS IDate
FROM DayOfMonth
WHERE Month(DateSerial(Year(Date()), Month(Date()), dd)) = Month(Date())