Results 1 to 8 of 8
  1. #1
    aamer is offline Competent Performer
    Windows 7 Access 2007
    Join Date
    Jul 2010
    Location
    Pakistan
    Posts
    224

    Display On Computer Screen But Not On Print

    Is it possible that a certain text of a report is visible/displayed on the computer screen (Print Preview Mode) and not when printed.

    Example: If a report has a reference no. and when i open the report it displays the reference no. but if printed it should not show the reference no.

    if this is possible how can i achieve this.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    49,229
    Can pass a value to report with OpenArgs then report reads its OpenArgs value to set textbox visibility depending on value read.

    However, if user is allowed to first open report in preview then send to printer, this approach fails.

    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.

  3. #3
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    1,391
    Open the report in design view and change the Display When property of the reference number text box to "Screen Only".
    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    49,229
    Rats, I tried to find that a while ago and completely missed it.
    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.

  5. #5
    aamer is offline Competent Performer
    Windows 7 Access 2007
    Join Date
    Jul 2010
    Location
    Pakistan
    Posts
    224
    I tried this but does not work

    i set the property value of text box to "Screen Only" but on screen it disappears (does not show) nor does it show in print

  6. #6
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    49,229
    Okay, then Print Preview is treated like it went direct to printer and Screen Only means Design, Layout, or Report view. This is because PrintPreview is supposed to be WYSIWYG as if sent to printer.

    So, back to my idea to use code which is starting to sound unattainable.

    If you don't want it to print then why need to display in preview?
    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.

  7. #7
    Cottonshirt is offline Advanced Beginner
    Windows 8 Access 2007
    Join Date
    Feb 2018
    Posts
    62
    I tried this but does not work
    i set the property value of text box to "Screen Only" but on screen it disappears (does not show) nor does it show in print
    that's because the DisplayWhen property only works in forms, not reports.

    reports are actually meant to be printed, so the idea of suppressing print in an object designed to be printed probably never occurred to any of those clever Microsoft wizards, it would be like including the option to not have wheels on your car.

    one thing I might be tempted to look at is conditional formatting, you might be able to format it to something that can be seen on a monitor but is so feint on paper it cannot be read. or you could try setting the colour to something your printer cannot handle.


    good luck with your project,



    Cottonshirt

  8. #8
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    49,229
    I disagree. I tested. It does work - for most controls. It is ignored for command button which will show only in Report view.
    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.

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

Similar Threads

  1. Charts won't print on one computer
    By BoydLabBuck in forum Reports
    Replies: 6
    Last Post: 09-19-2018, 01:04 PM
  2. Replies: 8
    Last Post: 01-31-2018, 01:43 PM
  3. Replies: 2
    Last Post: 09-28-2015, 05:52 PM
  4. Replies: 0
    Last Post: 02-24-2012, 11:16 AM
  5. print screen
    By SlowPoke in forum Access
    Replies: 1
    Last Post: 10-06-2010, 04:09 PM

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 - Senior Forums