Selasa, 10 April 2012

Re: [MS_AccessPros] Entering time

 

Bill

I really don't think setting the default value will work, but if you find a way to do it be sure to let us know.

Bill

--- In MS_Access_Professionals@yahoogroups.com, "Bill Singer" <Bill.Singer@...> wrote:
>
> Glen and Bill,
>
> This worked perfect. I would have never thought to put it in the after
> update property of the start time. I was trying to figure out how to add it
> as a default value in the field of the input form. Maybe that would have
> worked as well.
>
>
>
> Learning more every question.
>
>
>
> Thanks,
>
> Bill
>
> MN but heading to FL for a week.. with my computer
>
>
>
>
>
> From: MS_Access_Professionals@yahoogroups.com
> [mailto:MS_Access_Professionals@yahoogroups.com] On Behalf Of Glenn Lloyd
> Sent: Monday, April 09, 2012 4:53 PM
> To: MS_Access_Professionals@yahoogroups.com
> Subject: RE: [MS_AccessPros] Entering time
>
>
>
> [mailto:MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Bill
> Singer
> Sent: April-09-12 4:28 PM
> To: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> Subject: RE: [MS_AccessPros] Entering time
>
> Bill and Glen,
>
> I will give that a try tonight.
>
> Bill Singer
>
> From: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
>
> Bill
>
> Use the AfterUpdate event of the start time control like this:
>
> Private Sub cboStartTime_AfterUpdate()
> txtEndTime = DateAdd("h", 1, cboStartTime)
>
> End Sub
>
> That leaves the end time calculated, but the user can edit it, too.
>
> Regards,
> Bill Mosca, Founder - MS_Access_Professionals
> http://www.thatlldoit.com
> Microsoft Office Access MVP
> https://mvp.support.microsoft.com/profile/Bill.Mosca
>
> --- In MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com> , "Bill Singer"
> <Bill.Singer@> wrote:
> >
> > Glen,
> >
> > I would like a field for the calculated value as sometimes it may not be
> > exactly one hour.
> >
> >
> >
> > Can you point me in the right direction on the code?
> >
> >
> >
> > Bill Singer
> >
> >
> >
> > From: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > [mailto:MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Glenn
> Lloyd
> > Sent: Monday, April 09, 2012 2:12 PM
> > To: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > Subject: RE: [MS_AccessPros] Entering time
> >
> >
> >
> >
> >
> >
> >
> > Bill,
> >
> > If the stop time is ALWAYS 1 hour after the start time, you don't even
> need
> > to store. On the form where you are getting the data input, simply have an
> > unbound text box and assign it a value using the after update events of
> the
> > controls you are using to input the start. However if there is even a
> slight
> > possibility that the stop time will be more or less than one hour then you
> > will need a field for the calculated value.
> >
> > Glenn
> >
> > From: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > [mailto:MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Bill
> > Singer
> > Sent: April-09-12 1:51 PM
> > To: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > Subject: RE: [MS_AccessPros] Entering time
> >
> > Glen,
> >
> > I might try a combo box. Not exactly as you mentioned but similar. I
> > really do not need all 24 hours in a day.
> >
> > How about another question related to time. I have to enter start time and
> > stop time. The stop time is always 1 hour after the start time. Is there
> > any way to make the stop time default to the correct time after the start
> > time is entered. I am able to make default numbers but I am getting mixed
> > up with trying to make a default time period.
> >
> > Thanks for any help you can offer.
> >
> > Bill Singer
> >
> > From: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > [mailto:MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Glenn
> > Lloyd
> > Sent: Monday, April 09, 2012 10:40 AM
> > To: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > Subject: RE: [MS_AccessPros] Entering time
> >
> > Bill,
> >
> > It might be easier just to let the user enter the time. However you could
> > use two or three unbound comboboxes, one for the hour, one for the minute
> > and one for am/pm (or you could use option buttons for am/pm. For the row
> > source of the hours combo use a table with 24 records and for the minutes,
> a
> > table with 60 records. Use the after update event of the three controls to
> > calculate and store the time (this is a rare exception to the rule about
> not
> > storing calculated results.
> >
> > Glenn
> >
> > From: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > [mailto:MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com> ] On Behalf Of Bill
> > Singer
> > Sent: April-09-12 11:20 AM
> > To: MS_Access_Professionals@yahoogroups.com
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > <mailto:MS_Access_Professionals%40yahoogroups.com>
> > Subject: RE: [MS_AccessPros] Entering time
> >
> > I have a field that is formatted as a date/time field. The user has to put
> > in a time like "11:00 PM". I am wondering if there is a easier way to
> > enter time than typing the whole number. All of the other information in
> > the record is selected from combo boxes but at this point the user has to
> > move to the keyboard. Is there a way to pull up a menu that allow the user
> > to select a time?
> >
> > I suppose I could create a table to reference in a combo box but the
> number
> > of records would be huge.
> >
> > Bill Singer
> >
> > MN
> >
> > [Non-text portions of this message have been removed]
> >
> > [Non-text portions of this message have been removed]
> >
> > _____
> >
> > No virus found in this message.
> > Checked by AVG - www.avg.com
> > Version: 2012.0.1913 / Virus Database: 2411/4924 - Release Date: 04/09/12
> >
> > [Non-text portions of this message have been removed]
> >
> > [Non-text portions of this message have been removed]
> >
> >
> >
> >
> >
> > [Non-text portions of this message have been removed]
> >
>
> _____
>
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 2012.0.1913 / Virus Database: 2411/4924 - Release Date: 04/09/12
>
> [Non-text portions of this message have been removed]
>
> [Non-text portions of this message have been removed]
>
>
>
> _____
>
> No virus found in this message.
> Checked by AVG - www.avg.com
> Version: 2012.0.1913 / Virus Database: 2411/4925 - Release Date: 04/09/12
>
>
>
> [Non-text portions of this message have been removed]
>

__._,_.___
.

__,_._,___

Tidak ada komentar:

Posting Komentar