R
ryan.fitzpatrick3
is there away to program if statements too coincide with dates. for
example I have a combobox (cboxQuarter) with Q1,Q2,Q3,Q4 as values. I
have 2 other cboxes, cboxstartdate and cboxenddate where a person can
input which ever date they want into each and run the query and the
report will only show the data between those dates. (this is what I
want it doesn't work yet)
I'd like these calendar quarters to program a query to pull the dates
that go to each quarter, i.e. if I run Q1 then it'll run 1-1-2009 to
3-31-09. how would I go about this?
Do I put if statements in vba if me.cboxQuarter = Q1 then
me.cboxstartdate = 1-1-2009 and me.cboxenddate = 3-31-2009 else if
me.cboxQuarter = Q2, etc etc.
Thanks,
ryan
example I have a combobox (cboxQuarter) with Q1,Q2,Q3,Q4 as values. I
have 2 other cboxes, cboxstartdate and cboxenddate where a person can
input which ever date they want into each and run the query and the
report will only show the data between those dates. (this is what I
want it doesn't work yet)
I'd like these calendar quarters to program a query to pull the dates
that go to each quarter, i.e. if I run Q1 then it'll run 1-1-2009 to
3-31-09. how would I go about this?
Do I put if statements in vba if me.cboxQuarter = Q1 then
me.cboxstartdate = 1-1-2009 and me.cboxenddate = 3-31-2009 else if
me.cboxQuarter = Q2, etc etc.
Thanks,
ryan