[AccessD] First/last day of week

John Colby jwcolby at ColbyConsulting.com
Wed Jan 18 18:14:46 CST 2006


Yea, it just makes the huge selector set (a bunch of radio buttons?) into a
little combo box.  As long as your to/from text boxes are named the same as
I use you can just cut and paste the code in the form (the dim and the form
open) to get the class instantiated and running, otherwise you need to feed
in the names of your combo and to/from text boxes.


John W. Colby
www.ColbyConsulting.com 


-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Hale, Jim
Sent: Wednesday, January 18, 2006 5:29 PM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] First/last day of week

Muchas Gracias! I still use Julie's code so this is going to be pretty much
plug and play.
Jim Hale

-----Original Message-----
From: John Colby [mailto:jwcolby at colbyconsulting.com]
Sent: Wednesday, January 18, 2006 3:53 PM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] First/last day of week


It is very cool.  A combo where you select things like:

Last year
Last quarter
Last month
This year
This quarter
This month 

Etc etc.

Then when you select something in the combo, it sets a date range in a pair
of (typically unbound) text boxes, which you then use for queries.  The
class raises an after update event for the combo (and the same event for the
text boxes as well - you can do a custom date range) so that the form that
is using the class can then set filters, copy the dates somewhere etc.

This all started with the code by one Julie Schwalm, Backroads Data, circa
1999.  I of course changed it into a class and changed her list to a combo.

I have just added "This week" and "Today" to the list because I need to be
able to see those ranges as well.

If you want this thing:

1) Go to www.colbyconsulting.com
1a) Register if you haven't already
1b) Login
2) Click Example Code / Withevent Demos
3) Down about the middle you will see DateRangeWithEvents.zip.  Download
that.
4) Unzip it and open the file.  An example form should open.
5) play with the combo selecting different date ranges and watching the
To/From text boxes change
6) open the form to see how to use it in a form.

Notice that it uses events.  The class raises an event, and the form CAN (if
you need it to) sink that event and do something with the event.  The
example does sink the event and displays a message.  Simply delete the event
handler from the form to not have the event sunk in the form.

Enjoy.

John W. Colby
www.ColbyConsulting.com 


-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Hale, Jim
Sent: Wednesday, January 18, 2006 2:59 PM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] First/last day of week

A date range selector class? Now that sounds cool.
Jim

-----Original Message-----
From: John Colby [mailto:jwcolby at colbyconsulting.com]
Sent: Wednesday, January 18, 2006 11:56 AM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] First/last day of week


>Busy multitasking week ..?

OMG, you can't believe! I am to the point where I am using Outlook to
schedule blocks of my time for specific client tasks.  0800-1700 filled with
1/2 hr lunch and then 2100-midnight as well.  And that for the next couple
of weeks, and possibly beyond.

Thanks for the functions.  I integrated them into my Date Range selector
class and now have a "This week" selection.

John W. Colby
www.ColbyConsulting.com 


***********************************************************************
The information transmitted is intended solely for the individual or entity
to which it is addressed and may contain confidential and/or privileged
material. Any review, retransmission, dissemination or other use of or
taking action in reliance upon this information by persons or entities other
than the intended recipient is prohibited.
If you have received this email in error please contact the sender and
delete the material from any computer. As a recipient of this email, you are
responsible for screening its contents and the contents of any attachments
for the presence of viruses. No liability is accepted for any damages caused
by any virus transmitted by this email.
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com




More information about the AccessD mailing list