473,386 Members | 1,706 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Singling out fields on Continuous Forms

Cro
Dear Access Developers,

I am developing a form with 'default view' set to "continuous forms".
I am suffering with a problem I can't yet see a solution too.

Each record has many fields. Two fields I would like to add a little
extra functionality to are a check box and a combo box. More
explicitly, I would like the 'enabled' property of a combo box control
to be dependent on the value of a check box (a 'yes/no' field) in the
same record. When the check box is unchecked the combo box should be
available and when the check box is checked, the combo box should be
unavailable.

My efforts thus far have disabled every single combo box on the form
rather than only disabling the combo box for one particular record.
How can I ‘single out' particular controls for particular records?

I also have a related problem in another form.

I am using rectangles to show staff availability for certain hours of
a given day. My form (again with 'default view' set to "continuous
forms") is based on a table called 'Staff Hours' with fields:

Name (PK), Date (PK), 0000-0010, 0020-0030, .... , 2300-0000

(Where 2300-0000 holds the data 'yes' or 'no' depending on whether
that particular staff member is working on a particular date in the
hour 11pm to 12pm).

Unfortunately, when I set the colour of the rectangles according to
the data in the table, the colour is set for every rectangle on the
form rather than just for the particular record it is appropriate to.

These two problems are related and I'd be extremely grateful for a
solution.

What do you think?

Thank very much.

Regards,

Cro
Nov 13 '05 #1
2 3991
Cro,

Re: Checkbox and Combobox
Look at your form in design view. There is only one combobox there. When you see
your form in form view and you see multiple records, there is still one combobox
but an instance of that same combobox for each record. The long and short of it
is that if you disable the combobox, since there is only one, it will be
disabled in every instance, ie, every record. You need to change your logic to
something else rather than disabling the combobox. Take a loof at conditional
formatting to see if there is something there you might use.

Re: Staffhours Form
To begin with, your table has fundamental problems. The first problem is that
the table is not normalized. You should not have multiple time fields but rather
a table such as:
TblStaff
StaffID
FName
LName

TblTimeOfDay
TimeOfDayID
TimeOfDay

TblStaffAvailability
StaffAvailabilityID
StaffID
AvailabilityDate
TimeOfDayID
Available (Y/N)

The second problem in your current table is the field named "Date". Date is a
reserved word in Access and should not be used as a field name. Note above, I
used "AvailabilityDate" as the field name.

You now need a form/subform. The main form should be base on a query based on
TblStaff to be able to display staff records in alphabetical order. The subform
should be based on a query based on TblStaffAvailability. The LinkMaster and
LinkChild properties of the subform control should be set as StaffID. Again,
there is one control for each field in the subform so you can't set the the
color of the rectangle the way you are without setting the color of all
instances of the same rectangle. Rather, use conditional formatting here - it
will give you the effect you want.
--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
re******@pcdatasheet.com
www.pcdatasheet.com

"Cro" <th*******@hotmail.com> wrote in message
news:24**************************@posting.google.c om...
Dear Access Developers,

I am developing a form with 'default view' set to "continuous forms".
I am suffering with a problem I can't yet see a solution too.

Each record has many fields. Two fields I would like to add a little
extra functionality to are a check box and a combo box. More
explicitly, I would like the 'enabled' property of a combo box control
to be dependent on the value of a check box (a 'yes/no' field) in the
same record. When the check box is unchecked the combo box should be
available and when the check box is checked, the combo box should be
unavailable.

My efforts thus far have disabled every single combo box on the form
rather than only disabling the combo box for one particular record.
How can I 'single out' particular controls for particular records?

I also have a related problem in another form.

I am using rectangles to show staff availability for certain hours of
a given day. My form (again with 'default view' set to "continuous
forms") is based on a table called 'Staff Hours' with fields:

Name (PK), Date (PK), 0000-0010, 0020-0030, .... , 2300-0000

(Where 2300-0000 holds the data 'yes' or 'no' depending on whether
that particular staff member is working on a particular date in the
hour 11pm to 12pm).

Unfortunately, when I set the colour of the rectangles according to
the data in the table, the colour is set for every rectangle on the
form rather than just for the particular record it is appropriate to.

These two problems are related and I'd be extremely grateful for a
solution.

What do you think?

Thank very much.

Regards,

Cro

Nov 13 '05 #2
Cro
Thanks very much for the help. I was able to acheive all the
functionality I needed by using conditional formatting.

"PC Datasheet" <no****@nospam.spam> wrote in message news:<b1*****************@newsread2.news.atl.earth link.net>...
Cro,

Re: Checkbox and Combobox
Look at your form in design view. There is only one combobox there. When you see
your form in form view and you see multiple records, there is still one combobox
but an instance of that same combobox for each record. The long and short of it
is that if you disable the combobox, since there is only one, it will be
disabled in every instance, ie, every record. You need to change your logic to
something else rather than disabling the combobox. Take a loof at conditional
formatting to see if there is something there you might use.

Re: Staffhours Form
To begin with, your table has fundamental problems. The first problem is that
the table is not normalized. You should not have multiple time fields but rather
a table such as:
TblStaff
StaffID
FName
LName

TblTimeOfDay
TimeOfDayID
TimeOfDay

TblStaffAvailability
StaffAvailabilityID
StaffID
AvailabilityDate
TimeOfDayID
Available (Y/N)

The second problem in your current table is the field named "Date". Date is a
reserved word in Access and should not be used as a field name. Note above, I
used "AvailabilityDate" as the field name.

You now need a form/subform. The main form should be base on a query based on
TblStaff to be able to display staff records in alphabetical order. The subform
should be based on a query based on TblStaffAvailability. The LinkMaster and
LinkChild properties of the subform control should be set as StaffID. Again,
there is one control for each field in the subform so you can't set the the
color of the rectangle the way you are without setting the color of all
instances of the same rectangle. Rather, use conditional formatting here - it
will give you the effect you want.
--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
re******@pcdatasheet.com
www.pcdatasheet.com

"Cro" <th*******@hotmail.com> wrote in message
news:24**************************@posting.google.c om...
Dear Access Developers,

I am developing a form with 'default view' set to "continuous forms".
I am suffering with a problem I can't yet see a solution too.

Each record has many fields. Two fields I would like to add a little
extra functionality to are a check box and a combo box. More
explicitly, I would like the 'enabled' property of a combo box control
to be dependent on the value of a check box (a 'yes/no' field) in the
same record. When the check box is unchecked the combo box should be
available and when the check box is checked, the combo box should be
unavailable.

My efforts thus far have disabled every single combo box on the form
rather than only disabling the combo box for one particular record.
How can I 'single out' particular controls for particular records?

I also have a related problem in another form.

I am using rectangles to show staff availability for certain hours of
a given day. My form (again with 'default view' set to "continuous
forms") is based on a table called 'Staff Hours' with fields:

Name (PK), Date (PK), 0000-0010, 0020-0030, .... , 2300-0000

(Where 2300-0000 holds the data 'yes' or 'no' depending on whether
that particular staff member is working on a particular date in the
hour 11pm to 12pm).

Unfortunately, when I set the colour of the rectangles according to
the data in the table, the colour is set for every rectangle on the
form rather than just for the particular record it is appropriate to.

These two problems are related and I'd be extremely grateful for a
solution.

What do you think?

Thank very much.

Regards,

Cro

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Phil Stanton | last post by:
I have a form of club members with a continuous subform on it showing boat details. I hold the boat length and beam (in meters) in a table. On the subform I also calculate and show the imperial...
3
by: S P Arif Sahari Wibowo | last post by:
Hi! I would like to make an editable continous form, where most fields will be from table A and editable, except 1-3 fields are a glimpse into table B and uneditable. Table A relate to table B...
2
by: Shawn Yates | last post by:
I have a form with two subforms on it which are both continous forms. The subform on the left shows the tasks that the employee was assigned to accomplish (each as a seperate record) while the one...
2
by: panwala_bhavesh | last post by:
Thanks in advance... I have a form displaying the results of a query in a continuous form style. I want to be able to double-click on the key field of the form (a textbox, in this case a AssetID)...
5
by: Michael R | last post by:
Searching the net I've found a simple technique to add row numbers and alternate colors (for the even and the uneven row) to a continuous form. 1st step: Create a textbox, send it to background...
2
by: seltzer | last post by:
I am using Access 2000 but I also have the 2003 version. I am working on creating a data entry form in Access for a research study. Since there is a maximum of 255 fields per table in Access, I...
1
by: rpboll | last post by:
I am looking for the best way to accomplish the following continuous forms concept. There are Five Groups: A, B, C, D, E Each group has eight Members: a, b, c, d, e, f, g, h Each...
1
by: G04 | last post by:
Hi All, I have a continuous form with all records. For each field there is a combo in the form header and the form also contains a Toggle button "Apply Filter". When clicked, it changes to...
5
by: grahamib | last post by:
I have a form running in access 2003. The forms property is set to continuous forms so that all records from an underlying query can be diaplayed. On the form are 12 sets of fields from...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.