Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
add 1 day to date variable
Hello, hopefully somebody can help me,
I'm retrieving 2 records from an Access table, a start date and a due date. I'd like to retrieve a 3rd record, which would be the start date + 1. However, the following doesn't work: st = DatePart("d", rs.Fields("tasks.task_ass_date")) due = DatePart("d", rs.Fields("task_ddate")) next = st + 1 It gives me a compile error: expected: variable. Does anyone have any suggestions? Thanks in advance for any help, |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
add 1 day to date variable
Dave Try this
st = DatePart("d", rs.Fields("tasks.task_ass_date")) + 1 due = DatePart("d", rs.Fields("task_ddate")) "DaveMZ" wrote: Hello, hopefully somebody can help me, I'm retrieving 2 records from an Access table, a start date and a due date. I'd like to retrieve a 3rd record, which would be the start date + 1. However, the following doesn't work: st = DatePart("d", rs.Fields("tasks.task_ass_date")) due = DatePart("d", rs.Fields("task_ddate")) next = st + 1 It gives me a compile error: expected: variable. Does anyone have any suggestions? Thanks in advance for any help, |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
VBA/SQL date variable problem | Excel Programming | |||
Setting a Date variable | Excel Programming | |||
Assign a Date Variable within VBA Q | Excel Programming | |||
calc constant date from variable date & return with ability to rn. | Excel Worksheet Functions | |||
Compare Date in Cell VS a Variable Date to Hide Row | Excel Programming |