Page 1 of 2 12 LastLast
Results 1 to 15 of 26
  1. #1
    Perfac's Avatar
    Perfac is offline Expert
    Windows 10 Access 2016
    Join Date
    May 2016
    Location
    Centurion Pretoria
    Posts
    618

    Screen Configuration


    A bit more than 6 years ago I started teaching myself Access. I have always used a 19- or 21-inch monitor. It came up that I was concerned my app will not fit all screen sizes. Some good guy came up with a very lengthy code that was supposed to ensure all pages of my app fit all screen sizes, through a Module. Yesterday I connected a 42 Inch television to my computer, and I would like to use it as a screen. I disconnected the "size reset" Module from three forms for testing. The recommended screen resolution of 800 X 600 makes a mess of my app screen sizes in Access. All other software, games, internet or windows display perfectly. I tested all the resolutions in Windows10, 1360 X 768 is a resolution that I would like. All forms on my app comes close to displaying perfectly, but it overlaps to the right with say 2cm. I wouldn't like to adjust 250 forms one by one. I do not assume it a setting on the TV. After 2 days on it, it would be nice to find a solution. Thank you.

  2. #2
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    4,914
    Was it this code?
    https://www.isladogs.co.uk/automatic-form-resizing-1/

    as it mentions up to 22" monitor, but not higher?
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  3. #3
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    Your post is very vague. Some 'good guy' could be anyone.

    IF it was my automatic form resizing code, the latest version of the code works on large screen, high resolution monitors as well.
    That will be uploaded to my website within the next week or so
    However, be aware that Access has a built-in limit for form widths = 57.79 cm (22.75 inches) which cannot be exceeded

    Also, there is no recommended screen resolution.
    If you mean the 'base resolution' from which all forms are scaled up, that is a setting that you can easily alter in the declarations section of the module modResizeForm
    Make a backup then increase the value of DESIGN_HORZRES to e.g. 1400 and (if its in use) DESIGN_VERTRES to e.g. 900

    Click image for larger version. 

Name:	Capture.PNG 
Views:	33 
Size:	14.4 KB 
ID:	49207

    If that does look like the module code you are using, please read the 3-part article linked by @welshgasman carefully as it explains all you need to know
    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

  4. #4
    Perfac's Avatar
    Perfac is offline Expert
    Windows 10 Access 2016
    Join Date
    May 2016
    Location
    Centurion Pretoria
    Posts
    618
    My son worked with me three years ago, not since then. He found the code attached from someone. Ruben (son) advised me to add to every form on the load event "Reziseform Me". To me it seems it calls just one paragraph of the lengthy code attached. As said, the wish was that if our app is loaded on any computer, it should fit well. The very old monitors have square screens. I still learn form you as well. I hope it is possible to find one set of code that always fit well on any screen??

    On the attachment if the one form is opened, with Windows 10 screen resolution 1360 X 768 my forms look close to good, except it cut of 2cm to the right. I am still busy testing what you advised me earlier. Thank you. There are other reasons why I would like the setting 1360 X 768.
    Attached Files Attached Files

  5. #5
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    4,914
    Note, if you change the Scale of the display, in that it is no longer 100%, , that appears to affect the forms?
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  6. #6
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    @Perfac
    Yes I remember many threads from a few years ago where you mentioned Ruben frequently.

    Anyway, that is my form resizing code or rather its an old version of it.
    Since then I've made many changes including support for datasheet forms, split forms, navigation forms and the addition of an optional form zoom effect
    All of those are included in the latest published version on my website (3.75)
    I would STRONGLY recommend replacing the module modResizeForm with the newer version

    OR you can download and try the latest test version 3.83 which is almost ready for release (attached)
    I need to remove some old code & various outdated comments but its substantially what I will post to the website in the next week or so

    The newest version includes code to work with both very large hi-res monitors and portrait monitors.
    It also includes code to refresh the display when forms are dragged to another monitor of different size/resolution
    Finally it has code to ensure forms are not scaled up to try & exceed the form width limit (as that will cause display problems)

    Ruben told you to add ResizeForm Me to the load event of each form but there's something else that is vital & is stressed on the online articles
    Before you do anything else, you need to consider your form sizes in design view
    The form dimensions should be made so it would fill the screen completely if viewed at the 'base resolution' i.e. the DESIGN_HORZRES & DESIGN_VERTRES values

    Your Main Menu form is 38cm wide in design view. That is FAR too big for scaling up successfully
    If your DESIGN_HORZRES constant is set as e.g. 1400 and you view the form with a horizontal resolution of 1920 it will scale up by a factor of1920/1400 = 1.371 approx.
    1.371 x 38cm = 52.1 cm wide which is fairly close to the width limit = 57.79 cm

    If you use a hi-res monitor e.g. horizontal resolution = 3840, the scaling factor is doubled to 2.742 approx and the form should scale up to 2x52.1=104.2 cm ... which isn't allowed

    However, it will scale up by less than that as I ensure that forms fit the screen vertically

    The new code will further restrict the scaling factor (where necessary) to prevent display issues on hi-res monitors.

    Automatic form resizing (AFR) works extremely well PROVIDING the guidelines are followed
    If not, the results will be disappointing or worse

    If you want to continue using AFR on a huge monitor, you really need to do one or both of the following
    a) reduce the size of your forms & their controls in design view
    b) increase the values of the two constants significantly

    Unless you do so, you will definitely not get good results
    Attached Files Attached Files
    Last edited by isladogs; 11-27-2022 at 04:26 PM. Reason: Updated attached file
    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

  7. #7
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    Quote Originally Posted by Welshgasman View Post
    Note, if you change the Scale of the display, in that it is no longer 100%, , that appears to affect the forms?
    The Windows setting scaling factors work as follows
    Say you have a resolution of 1680 x 1050 and you then change the scaling factor to 125% (5/4)
    That means that the effective resolution is reduced to 4/5 of the stated value 1344x840
    When refreshed, the forms will adjust to that new resolution

    In the latest version, all the main forms include a textbox showing the current resolution and a Refresh button to update the display
    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
    Perfac's Avatar
    Perfac is offline Expert
    Windows 10 Access 2016
    Join Date
    May 2016
    Location
    Centurion Pretoria
    Posts
    618
    Thanks Colin. I continue at this moment. I will do what you suggest and reply. Happy to learn that Ruben got the code from you.

  9. #9
    Perfac's Avatar
    Perfac is offline Expert
    Windows 10 Access 2016
    Join Date
    May 2016
    Location
    Centurion Pretoria
    Posts
    618
    I replaced Module "modResizeForm(Code)" with the one you sent me.
    Attachment 49210
    Attached Thumbnails Attached Thumbnails 221127a.png  

  10. #10
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    OOPS!
    Just fixed that declaration for 64-bit & replaced the attachment in post #7. Hopefully OK now.
    Forgot to say that you also need to import the other modules if you don't already have them
    Module modMonitorInfo is new.
    Also remember to make a backup before you do anything else

    Recommend you spend time checking out the functionality of each item in the example app before you do anything else so you can see how it works
    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

  11. #11
    Join Date
    Jan 2017
    Location
    Swansea,South Wales,UK
    Posts
    4,914
    Quote Originally Posted by isladogs View Post
    The Windows setting scaling factors work as follows
    Say you have a resolution of 1680 x 1050 and you then change the scaling factor to 125% (5/4)
    That means that the effective resolution is reduced to 4/5 of the stated value 1344x840
    When refreshed, the forms will adjust to that new resolution

    In the latest version, all the main forms include a textbox showing the current resolution and a Refresh button to update the display
    Colin. I mentioned it as the tracker form in your CERT DB does not resize correctly for me, as I have to scroll down to get the horizontal scrollbar.
    Yet when I amended the display to 100% the resize worked as it should.

    However with my eyesight these days, I need the 125%
    Please use # icon on toolbar when posting code snippets.
    Cross Posting: https://www.excelguru.ca/content.php?184
    Debugging Access: https://www.youtube.com/results?sear...bug+access+vba

  12. #12
    Perfac's Avatar
    Perfac is offline Expert
    Windows 10 Access 2016
    Join Date
    May 2016
    Location
    Centurion Pretoria
    Posts
    618
    Thanks for the effort as well, Mr. Welshgasman.

    Colin. Yes, I test on a backup.
    I imported all 9 Modules, after deleting the old modResizeform.
    Now opening any form, it flashes the content and then displays no content.

  13. #13
    Perfac's Avatar
    Perfac is offline Expert
    Windows 10 Access 2016
    Join Date
    May 2016
    Location
    Centurion Pretoria
    Posts
    618
    I watched some of your clips about this subject. Trying to open most forms on your attachment it errors the following.

    Click image for larger version. 

Name:	221127b.png 
Views:	27 
Size:	70.7 KB 
ID:	49213

  14. #14
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    Apologies.
    Thought I had checked all the latest code in 64-bit but obviously not.
    Its late here now but will look at modMonitorInfo again tomorrow on my 64-bit machine
    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

  15. #15
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,974
    OK - found the 64-bit declaration errors in modMonitorInfo.
    It now compiles and runs without error in 64-bit Access

    The only thing I haven't been able to check is dragging forms to a new monitor in 64-bit but I doubt that will be a problem
    Attached Files Attached Files
    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

Page 1 of 2 12 LastLast
Please reply to this thread with any new information or opinions.

Similar Threads

  1. Access network design: FE configuration
    By Blings in forum Access
    Replies: 6
    Last Post: 07-14-2021, 03:34 PM
  2. Replies: 4
    Last Post: 03-16-2017, 04:04 AM
  3. Split configuration names
    By fuecheefang in forum Queries
    Replies: 6
    Last Post: 07-05-2016, 03:59 PM
  4. Replies: 2
    Last Post: 01-28-2014, 12:04 PM
  5. configuration failed
    By PURAN in forum Access
    Replies: 1
    Last Post: 05-15-2012, 03:39 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