Free Lessons
Courses
Seminars
TechHelp
Fast Tips
Templates
Topic Index
Forum
ABCD
 
Home   Courses   TechHelp   Help   Contact   Merch   Join   Order   Logon   Forums   
 
Home > Forums > Access Forum > Image Control Size by David Clement
Back to Access Forum    Comments List
Upload Images | @Reply | Bookmark | Link | Email | Next Unseen |
Image Control Size
David Clement 
      
6 hours ago
Good morning Richard, and others.
This question has probably been asked before, if so, I am sorry.
Is there a way to set the Image Control to set an image at or near it's original size?
I am mostly working with images that are set at 1920 x 1080 so they can be used for desktop walllpaper and just have full screen images. Every time I try to do this, the image inside the control is always smaller than the original even setting the control to zoom. I've looked at the width and height properties and still can't quite get there. What if anything can I do?
Thank you!
Donald Blackwell  @Reply  
        
5 hours ago
Hi David, I've messed with this a few times and ran into similar results as you in the past using the image control. What I did to get the result I wanted (showing each image at its original size) was to create a blank form (on the ribbong: Create -> Form Design).

In the properties pane for the form, choose the format tab.
Picture Type: Linked
Picture: [choose the path to your image - this can be managed programmatically in VBA as well)
Picture Tiling: No
Picture Alignment: Center - this will place the image at or near the exact center of the screen - similar to photo viewer
Picture Size Mode: Clip - this may seem counter intuitive, but it works once the form loads
Border Style: None
Record Selectors: No
Navigation Buttons: No
Scroll Bars: None - I use code to enable scroll bars if I have a very large image and I want to scroll to see it all

On the Other tab, set Popup to Yes, this ensures the full screen is available, however may have issues if you have multiple monitors but that can also be managed with code.

Lastly, on the Events tab, in the Form On Load event, go to code builder and add "DoCmd.Maximize"

This will load the form and show the indicated image  with the form in full screen view and the image at or near the center of the screen.

Things that help include setting a background color for your detail section if you don't want blinded by a white background behind your image. You can also bind your form to a table and have the On Current event change the "Picture" property of the form to the current record and handle any file path. You could set a button with arrow at the left and right of the form to navigate to next and previous, etc. Pretty much however you want it to look.
Donald Blackwell  @Reply  
        
5 hours ago
I should add, that I added some mouse/keyboard functionality for clicking on the form anywhere to close the photo view and have some hidden navigation as well. For example:
Details
Private Sub Detail_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
  
   If Shift = 1 Then
   ' Shift Pressed - Move Picture to next record in table or return to the first record
      If SelTop < Me.Recordset.RecordCount Then
      ' SelTop is the current position of the record cursor in the assigned record source
         SelTop = SelTop + 1
      Else
      ' Already at the last record, so go back to the first
         SelTop = 1
      End If
   ElseIf Shift = 2 Then
   ' The Control Key is pressed so go to the previous record or last record if already at the first record
      If SelTop > 1 Then
         SelTop = SelTop - 1
      Else
      ' Already at the first record, so circle to the last
         SelTop = Me.RecordSet.RecordCount
      End If
   ElseIf Shift = 4 Then
   ' The ALT Key is pressed, so close the Image Viewer Form
      DoCmd.Close acForm, Me.Name, acSaveYes
   End If

End Sub
Donald Blackwell  @Reply  
        
5 hours ago
Also, if you have issues with it not navigating to the last record initially with the code provided, then you likely have a lot more records in your table than I had so You may want want to do some behind the scenes record navigation with a recordset or clone and store the count in a variable to get the correct record count.
David Clement OP  @Reply  
      
4 hours ago
Thank you for the help!
Richard Rost  @Reply  
          
4 hours ago
Thanks for helping out, Donald. David, the key distinction is that Zoom fits the whole image inside the available space while keeping its proportions. Clip displays it at its original size, but any part that does not fit will be cut off. That applies to an image control too, so you can try Clip there as well as Donald's form-background approach.
Add a Reply Upload an Image
Next Unseen

 
 
What's This?

 

The following is a paid advertisement
Computer Learning Zone is not responsible for any content shown or offers made by these ads.
 

Learn
 
Access - index
Excel - index
Word - index
Windows - index
PowerPoint - index
Photoshop - index
Visual Basic - index
ASP - index
Seminars
More...
Customers
 
Login
My Account
My Courses
Lost Password
Memberships
Student Databases
Change Email
Info
 
Latest News
New Releases
User Forums
Topic Glossary
Tips & Tricks
Search The Site
Code Vault
Collapse Menus
Help
 
Customer Support
Web Site Tour
FAQs
TechHelp
Consulting Services
About
 
Background
Testimonials
Jobs
Affiliate Program
Richard Rost
Free Lessons
Mailing List
PCResale.NET
Order
 
Video Tutorials
Handbooks
Memberships
Learning Connection
Idiot's Guide to Excel
Volume Discounts
Payment Info
Shipping
Terms of Sale
Contact
 
Contact Info
Support Policy
Mailing Address
Phone Number
Fax Number
Course Survey
Email Richard
[email protected]
Blog RSS Feed    YouTube Channel

LinkedIn
Copyright 2026 by Computer Learning Zone, Amicron, and Richard Rost. All Rights Reserved. Current Time: 10/31/2026 5:15:40 PM. PLT: 0s