My Assistant
![]() ![]() |
|
|
Jul 26 2011, 09:56 AM
Post
#1
|
|
|
UtterAccess Addict Posts: 181 |
Hi:
I have a table (Students) with a checkbox (Yes/No) field (EnrolledOnly). I also have a subreport with the following Record Source and Query: SELECT HighestFrequency10SchoolDaysQuery.Student, HighestFrequency10SchoolDaysQuery.CountOfTimeOOP FROM HighestFrequency10SchoolDaysQuery WHERE (((HighestFrequency10SchoolDaysQuery.CountOfTimeOOP)>1)); SELECT TOP 15 HallwayMilieuTable.Student, Count(HallwayMilieuTable.TimeOOP) AS CountOfTimeOOP FROM HallwayMilieuTable WHERE (((HallwayMilieuTable.dDate) In (Select Top 10 SchoolDates From [SchoolCalendar2010-2011Table] Where SchoolDates <= Date() Order By SchoolDates Desc )) AND ((HallwayMilieuTable.OOP)=True)) GROUP BY HallwayMilieuTable.Student ORDER BY Count(HallwayMilieuTable.TimeOOP) DESC; It all works fine but what I want to do is use conditional formatting to change the font color when a student is enrolled only (check box "Yes") meaning they are discharged. I’ve searched for over an hour on how to do this but can’t find anything helpful. Thanks, xeb |
|
|
|
Jul 26 2011, 09:58 AM
Post
#2
|
|
|
UtterAccess VIP Posts: 8,189 From: Pacific NorthWet |
You mentioned a table, a report and queries. Where are you attempting to use conditional formatting?
One idea might be to use a query to show that checkbox field, then use a report that uses that query, then use conditional formatting in the report design when the checkbox field is set your way... |
|
|
|
Jul 26 2011, 10:04 AM
Post
#3
|
|
|
UtterAccess Addict Posts: 181 |
I want to use the conditional formatting in the subreport in the "Student" field. I did create a query that returns the (currently) five students who have enrolled only status but I don't know how to apply it (make it work in conjunction with the HallwayMilieuTable.) Thanks.
|
|
|
|
Jul 26 2011, 10:12 AM
Post
#4
|
|
|
UtterAccess VIP Posts: 2,472 From: Columbia, Maryland |
You need to return the enrolledonly field in your query. Then you can use it in the conditional formatting for the student control by using
EXPRESSION IS : [EnrolledOnly] = True |
|
|
|
Jul 26 2011, 10:26 AM
Post
#5
|
|
|
UtterAccess Addict Posts: 181 |
Thanks, but that doesn't work because the subreport draws its data from the "HallwayMilieuTable" and the "EnrolledOnly" field is in the "Students" table. I tried various versions of the following but that doesn't work either.
Expression Is: ("[EnrolledOnly]","Students") = True |
|
|
|
Jul 26 2011, 10:27 AM
Post
#6
|
|
|
UtterAccess VIP Posts: 8,189 From: Pacific NorthWet |
Any reason why you couldn't/wouldn't join the two together to "get" the checkbox value in your subreport's query?
|
|
|
|
Jul 26 2011, 12:04 PM
Post
#7
|
|
|
UtterAccess Addict Posts: 181 |
I figured out a way to do it. I put the "Students" table on the subreport query and it works now. Thanks for your help.
|
|
|
|
![]() ![]() |
|
Go to Top · Lo-Fi Version | Time is now: 18th June 2013 - 05:12 PM |