interesting vba/access question: color rectangles according to data

Posted by every_answer_gets_a_point on Stack Overflow See other posts from Stack Overflow or by every_answer_gets_a_point
Published on 2010-05-25T17:10:09Z Indexed on 2010/05/25 17:11 UTC
Read the original article Hit count: 182

Filed under:
|
|

i have a datasheet that looks like this:

ID  name_   1   2   3   4
1   name1   x   0   0   0
2   name2   0   x   0   0
3   name3   0   0   x   0
4   name4   0   0   0   x

i have rectangles on a report that correspond to this datasheet.

when the report opens, i need the rectangles to be colored RED according to the data. for example where name1 and there is an x in the 1 column, i need the specific rectangle corresponding to this (name1, 1) to be colored red. here is the result that i will need:

x           
    x       
        x   
            x

(where x is a rectangle that is RED)

perhaps the best place to place this code would be in ON LOAD event of the report, but i am not sure exactly.

can you please suggest to me some code that would turn the specified rectangles RED according to the data?

© Stack Overflow or respective owner

Related posts about sql

Related posts about ms-access