Results 1 to 4 of 4
  1. #1
    Ekhart is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2016
    Posts
    80

    Adding text to box based on criteria used

    I have a report that shows all records that need action done to them. This may be 'Needs Appt. Date' or 'Appt has passed' or 'Follow up on Letter Sent'. Each criteria line in my query refers to one of these reasons. I can use conditional formatting easy enough to highlight something but rather than using 20 different colors, each indicating a specific issue, I wanted to add a text box to the beginning of the report that would simply say 'Needs Appt. Date' on a line and 'Follow up on Letter' on, for instance, the next line if that line used THOSE criteria to land it on the report.



    I included a snip of my query form rather than trying to explain what my criteria are.
    Attached Thumbnails Attached Thumbnails Capture.JPG  

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,524
    put the fields on the report, make them invisible.
    in the report turn them on if needed in the ON PRINT event
    txtNeedsAppt.visible = NeedsAppt.value
    txt'FollowLtr.visible = Followup.value

  3. #3
    Ekhart is offline Advanced Beginner
    Windows 10 Access 2016
    Join Date
    Jun 2016
    Posts
    80
    But how to I make them invisible based on a line of criteria? Where would I put code for this, just in the invisible field?

  4. #4
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,524
    when the report runs, the ON PRINT detail event,
    it will either hide it /or visible based on your field value.
    txtFollowLtr.visible = Followup.value

Please reply to this thread with any new information or opinions.

Similar Threads

  1. find values based on text criteria
    By boboivan in forum Access
    Replies: 2
    Last Post: 12-09-2015, 05:37 AM
  2. disable text box based on criteria
    By DCV0204 in forum Forms
    Replies: 4
    Last Post: 01-31-2014, 02:38 PM
  3. Counting text entries based on criteria
    By benjammin in forum Queries
    Replies: 6
    Last Post: 07-22-2013, 09:55 AM
  4. Replies: 3
    Last Post: 11-24-2012, 05:35 PM
  5. Summation of Types (based on text criteria)
    By justinwright in forum Reports
    Replies: 4
    Last Post: 01-26-2011, 01:07 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums