Selecting standard input on form

S

Susie

Hi!

I am trying to set up a database which will log the amount of time that
employees have spent on certain projects and tasks throughout the day.

What I want to do is create some sort of entry form, in that an employee can
select their name and the date and then enter all the times that they have
spent on specific tasks and projects.

At present, the fields in my table are - Name, date, project, task and hours.

Name and date will remain stagnant throughout the person entering the info,
as they will be required to do this on a daily basis. But in any one day
they may be working on 3 different projects, and 4 different tasks.

For example, today i have worked 1 hour on 'TTF' project, 'databases' task,
2 hours on 'internal' project, 'reporting' task and 3 hours on 'HRV' project,
'training development' task.

Is there some way that i can write an entry form which will allow me to keep
my name and date constant, but enter multiple diferentiating lines for the
project/task/hours fields?? I just don't want people to be spending alot of
time re-entering their name and date for each line.

Any help would be most appreciated.

Thanks in advance,

Susie
 
T

tina

suggest you normalize your table design first; employee and date are common
to the subsequent records, so they should be in another table where they're
only entered once. recommend 4 tables:

tblEmployees
EmpID (primary key)
FirstName
LastName
(this table is a list of all employees you're tracking.)

tblProjects
ProjID (pk)
ProjName
(this table is a list of all projects you're tracking.)

tblTasks
TaskID (pk)
TaskName
(this table is a list of all tasks that may be done for all projects. note:
list each task only once. for instance, if two different projects may each
have a "reporting" task, you would list "Reporting" in this table only
once.)

tblWorkHours
WorkHourID (pk)
fkEmpID (foreign key from tblEmployees)
WorkDate
fkProjID (fk from tblProjects)
fkTaskID (fk from tblTasks)
WorkHours

relationships
tblEmployees 1:n tblWorkHours
tblProjects 1:n tblWorkHours
tblTasks 1:n tblWorkHours

the above is a standard relational data design. a standard data entry format
would be a main form, bound to tblEmployees, with a subform bound to
tblWorkHours. in the subform, field fkProjID would be bound to a combo box
whose RowSource would be tblProjects; field fkTaskID would be bound to a
combo box whose RowSource would be tblTasks.

to simplify entering the date for each record in tblWorkHours, you could add
an unbound textbox to the main form, where the user would enter the date. in
the subform, set the DefaultValue of the WorkDate control to
=Forms!MainFormName!UnboundTextboxName

so the data entry flow would be: user opens main form and enters his/her
name and the date. then tabs to the subform and enters a record for each
project name, task, and hours worked.

hth
 
T

Tom Wickerath

Susie,

To add just a little bit to Tina's excellent answer, you might notice that
she used WorkDate, FirstName and LastName as field names instead of Date and
Name as you originally suggested. Date and Name are reserved words in Access.
You will do good to avoid using reserved words for anything in Access that
you assign a name to. Here are two KB (Knowledge Base) articles that you
might want to look at:

Reserved Words in Microsoft Access
http://support.microsoft.com/?id=286335

List of reserved words in Jet 4.0
http://support.microsoft.com/?id=321266


Tom
___________________________________________

:

suggest you normalize your table design first; employee and date are common
to the subsequent records, so they should be in another table where they're
only entered once. recommend 4 tables:

tblEmployees
EmpID (primary key)
FirstName
LastName
(this table is a list of all employees you're tracking.)

tblProjects
ProjID (pk)
ProjName
(this table is a list of all projects you're tracking.)

tblTasks
TaskID (pk)
TaskName
(this table is a list of all tasks that may be done for all projects. note:
list each task only once. for instance, if two different projects may each
have a "reporting" task, you would list "Reporting" in this table only
once.)

tblWorkHours
WorkHourID (pk)
fkEmpID (foreign key from tblEmployees)
WorkDate
fkProjID (fk from tblProjects)
fkTaskID (fk from tblTasks)
WorkHours

relationships
tblEmployees 1:n tblWorkHours
tblProjects 1:n tblWorkHours
tblTasks 1:n tblWorkHours

the above is a standard relational data design. a standard data entry format
would be a main form, bound to tblEmployees, with a subform bound to
tblWorkHours. in the subform, field fkProjID would be bound to a combo box
whose RowSource would be tblProjects; field fkTaskID would be bound to a
combo box whose RowSource would be tblTasks.

to simplify entering the date for each record in tblWorkHours, you could add
an unbound textbox to the main form, where the user would enter the date. in
the subform, set the DefaultValue of the WorkDate control to
=Forms!MainFormName!UnboundTextboxName

so the data entry flow would be: user opens main form and enters his/her
name and the date. then tabs to the subform and enters a record for each
project name, task, and hours worked.

hth
____________________________________________


Hi!

I am trying to set up a database which will log the amount of time that
employees have spent on certain projects and tasks throughout the day.

What I want to do is create some sort of entry form, in that an employee can
select their name and the date and then enter all the times that they have
spent on specific tasks and projects.

At present, the fields in my table are - Name, date, project, task and hours.

Name and date will remain stagnant throughout the person entering the info,
as they will be required to do this on a daily basis. But in any one day
they may be working on 3 different projects, and 4 different tasks.

For example, today i have worked 1 hour on 'TTF' project, 'databases' task,
2 hours on 'internal' project, 'reporting' task and 3 hours on 'HRV' project,
'training development' task.

Is there some way that i can write an entry form which will allow me to keep
my name and date constant, but enter multiple diferentiating lines for the
project/task/hours fields?? I just don't want people to be spending alot of
time re-entering their name and date for each line.

Any help would be most appreciated.

Thanks in advance,

Susie
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top