back color in cells/fields on datasheet view

G

Guest

Hi. I would to know if it is possible to set a back color in cells/fieds when
the form view is set to datasheet? I know that if the view is set to single
form it works, but in datasheet view I can't.

Another thing in the same form with datasheet view is, if I've got to
line/records and one field/column as the same value can I set a back color to
the whole line/record?

Regard,
Marco
 
G

Guest

Marco Silva said:
Hi. I would to know if it is possible to set a back color in cells/fieds when
the form view is set to datasheet? I know that if the view is set to single
form it works, but in datasheet view I can't.

This can be done for datasheet views. When in design mode, you can select
each control and set its back color or use Conditional Formatting on any
control. There is no difference from Form view.
Another thing in the same form with datasheet view is, if I've got to
line/records and one field/column as the same value can I set a back color to
the whole line/record?

The easiest eay to do this is to create a column in your form's query that
returns True if it is a duplicate. You can get some idea of how to do this by
creating a query using the Find Duplicates Query Wizard. The result of this
should be that the new column shows a checkbox which is checked if the record
is a duplicate.

Back in your form, select all the controls in the datasheet view and click
Format, Conditional Formatting. Select Expression Is and enter a reference to
the new true/false column, like this:
MyDuplicateRecColumn = True
(replace the name of the column with your own)

Then apply a back color format when this expression is true by choosing a
color from the paint bucket dropdown.

For what it's worth, you should probably design the tables, indexes, and
relationships better to prevent duplicates in the first place. This sometimes
isn't possible, if you're importing or merging data from other sources, but
it's the right way to design the database.

Barry
 
G

Guest

Hi. I have primary keya and relationships. Sometimes I need to have to lines
with the same data.

About back colors, I just wanted to show to users that those fieds were
filed automatically.

Thanks.
 

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