Conditional formatting on report

  • Thread starter Thread starter Darhl Thomason
  • Start date Start date
D

Darhl Thomason

We are in the midst of a rollout to our company's stores. We are assisting
the franchise owners with their first three stores, but after that, they're
on their own. I want to be able to have my schedule report reflect this by
highlighting the owner's name only if they still need assistance with their
stores. I can handle the highlighting part, it's the logic that's getting
me.

Also, I don't know if the report is the correct place to code this, or if I
should code this on the form and pass it to the report. I originally
thought about creating a Boolean field for if they need assistance or not,
but this seems like a calculated field and I've read enough in the
newsgroups to know that I really don't want to store a calculated field.

So, I have StatusID that reflects if they are scheduled (StatusID=2) or if
they are completed (StatusID=1). I need to check this for each owner
(OwnerID), so basically if I have OwnerID=1 with 5 stores total and
StatusID=1 on 3 or fewer stores, then turn the highlight on, otherwise turn
the highlight off. I think I would need to look through the recordset of
scheduled stores and break out the different owners (possibly load them into
an array???) Then do the check for each different owner.

I'm kind of stuck on how to start this, so any help or idea is appreciated.

Thanks,

Darhl
 
Hi,
how is your status field any different then a boolean field. You are storing
two options (either 1 or 2/ either true/false, on/off...). A calculated field
is what it says...a field which holds the value of a calculation. Your case
does not represent a calculation at all, so a yes/no datatype field would be
ok if you wanted that. You can then use a query to filter out ALL records
which have a true in the yes/no field. Then you can base a report on this
query and show them and if you want highlight them.
HTH
Good luck
 
Well, the StatusID really isn't Boolean because there are other possible
values for StatusID. StatusID = 3 means Pending (they have not ordered
their system yet), StatusID = 4 means Ordered (they have ordered but are not
scheduled yet).

I guess I should have mentioned all the possibilities for StatusID.

I am envisioning parsing through the owners that have at least one store
with StatusID = 2 and for each owner counting the number of times that
StatusID = 1 and if that count is =< 3 then highlight their name on the
installation schedule report to signify they still need assistance with
their installation and training.

Darhl
 

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

Back
Top