Results 1 to 11 of 11
  1. #1
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581

    Check mark

    I have a report where I have a yes/no field. I need the report to have 2 check marks. One has to be "Yes" and the other "No". However, my table only has the one field which is yes/no. I'm trying to find a way to populate the "No" check mark if the the "Yes" check mark is null. Ideas?

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    no, 1 check box is either YES or NO.
    checked means yes....unchecked means no.
    the checkbox is bound to 1 field with a field type of boolean (yes or no, aka true/false, aka on/off)

    you dont (and cant) have 2 checks.

  3. #3
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,921
    Your requirement doesn't really make sense. If there is no field then what purpose does the second checkbox serve?

    You can have a textbox bound to yes/no field and format to display "Yes" or "No".

    However, as ranman said, yes/no field is either yes or no, never Null.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  4. #4
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,977
    The OP wants to have two separate checkboxes for the same field so that one or other is ticked
    So if the user ticks Yes, No is automatically unticked (& vice versa)
    An odd way of doing things but it should be perfectly possible

    However I think it will confuse end users rather than help them
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

  5. #5
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581
    I'm not sure I'm being clear about what I'm trying to do. The report is purely aesthetics for those who think it should look a certain way. My form enters everything fine. However, to please those that want to see the report in a particular format, I'm trying to keep it just so. I have 2 yes/no fields on my report. Only 1 actually carries any information. The second has no control at all. What I'm trying to accomplish is to make it so that if field 1 is 0, the one with no control sees it and puts a check mark, yes, -1, true.... I tried to put in; =if [field1],false,true That didn't work. I tried =if [field1],-1,0 That also didn't work either. I was hoping someone might have another possibility.

  6. #6
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581
    Ridders, yes. That's exactly what I'm trying to do. I know it's strange, but that's how they want it. People like their check marks.

  7. #7
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,977
    In other words, roughly what I suggested

    Its easy enough to achieve in a form
    Set the first control bound to your yes/no field e.g. [Field1]
    Set the control source for the second checkbox equal to
    Code:
    =Not([Field1])
    If the first is checked, the second won't be ...and vice versa
    Ticking the unchecked one will toggle the checkboxes ... no code needed

    Tested in a form
    Reports are not really intended to be interactive
    I don't think it is possible to update checkboxes for a report in report view
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

  8. #8
    UT227 is offline Expert
    Windows 7 32bit Access 2013 32bit
    Join Date
    Feb 2016
    Posts
    581
    It was exactly like you suggested. It worked perfectly in a report too. That was great. Thanks.

  9. #9
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,977
    You're welcome. Glad the report also worked though I didn't expect it would do so.
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

  10. #10
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,921
    I expect OP is not clicking on the bound checkbox in report, just conditionally displaying value of second checkbox. Certainly nothing unusual about using expressions in report design, it's just this checkbox arrangement is odd.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  11. #11
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,977
    The reason I was surprised is that I also tested it using a report in report view before I posted - it wasn't possible to update them
    As I originally said, the method is perfectly simple to apply but IMO confusing for end users
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

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

Similar Threads

  1. Show check mark in report
    By MAD3654 in forum Programming
    Replies: 1
    Last Post: 10-28-2016, 05:29 PM
  2. Replies: 4
    Last Post: 04-18-2014, 06:14 AM
  3. Replies: 1
    Last Post: 06-26-2012, 03:06 AM
  4. Can a Check-mark be displayed in a Listbox
    By caddcop in forum Forms
    Replies: 3
    Last Post: 04-26-2011, 03:27 PM
  5. Mark the difference
    By zhshqzyc in forum Access
    Replies: 1
    Last Post: 01-28-2011, 08:49 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