Making checkboxes priorty over others

scottemotive

Registered User.
Local time
Today, 02:55
Joined
Oct 13, 2004
Messages
36
Hi
My db is below
http://emotiveexposed.mysite.wanado....co.uk/test.mdb

i have a series of checkboxes in sections

Compliance and Quality

here is my required scenario
what i want is if compliance checkbox.value = 1 then flagawarded = "Red Flag"
else "n/a"
if quality checkbox.value = 1 then flagawarded = "amber flag"
but if both compliance checkbox.value = 1 AND quality.value = 1 then flagawarded = "Red Flag"
so that red flags are priorty over amber flags even tho they are both ticked

also related to this question how can i get evaluationscore.value = "n/a" if flagawarded = "Red Flag"

thank you
 
Would this work:


Code:
if compliance checkbox.value = 1 and quality checkbox.value = 1 then
   flagawarded = "Red
   evaluationscore.value = "n/a" 
else if compliance checkbox.value = 1 then
   flagawarded = "Red 
   evaluationscore.value = "n/a"
else if quality checkbox.value = 1 then
   flagawarded = "amber flag"
end if

kh
 
would i put this on the compliance checkboxes (on click ) which is the one that takes priorty or quaity
 
I would put it in stand alone sub procedure and call it from both of the check boxes afterupdate events.

kh
 
thank you for this
still playing with this at the moment,
however what happens if quality is clicked and then compliance is clicked, red flag still needs to take priorty
if you have a look at my db(if you havnt already) you will get more of an idea than i can explain here

thank you
 
scenario:

if compliance = 1 then flagawarded = "red flag" and totalevaluationscore = "n/a"

if compliance = 1 and quality = 1 then flagawarded = "red flag" and totalevaluationscore = "n/a"

if compliance = 0 and quality = 1 then flagawarded = "amber flag" and total evaluation score = "the calculated value it should be based on my sub precedure"

if compliance = 0 and quality = 0 then flagawarded = "None" and total evaluation score = "90"

these are the four possiblities, however i need these rules to apply at all times as the checkboxes can be unclicked (i.e if they were clicked accidentally)

can anyone tell me how i can structure this and where i would put the code based on my db

thank you
 

Users who are viewing this thread

Back
Top Bottom