If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
back color in cells/fields on datasheet view
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 |
#2
|
|||
|
|||
back color in cells/fields on datasheet view
"Marco Silva" wrote:
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 |
#3
|
|||
|
|||
back color in cells/fields on datasheet view
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. "Barry Gilbert" wrote: "Marco Silva" wrote: 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 |
Thread Tools | |
Display Modes | |
|
|