Results 1 to 12 of 12
  1. #1
    mr_right is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Mar 2013
    Posts
    11

    Use buttons to navigate and open current attachment


    Hello.
    Good day!
    i am new here and beginner in microsoft access.
    Just want to ask if it is possible to use buttons to navigate/open attachment?
    I have two tables (itemTbl and ItemcomponentTbl) and a form.
    Inside formare itemtbl field names (w/c include the attachment) and a componenttbl subform.
    Hopefully someone will help me on this.
    Thanks in advance.
    Captured DB attached.
    Click image for larger version. 

Name:	Picture1.jpg 
Views:	25 
Size:	68.3 KB 
ID:	11808

  2. #2
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    Are you storing a path to the picture of the part in your database?

    Here's an example that's a bit easier to use:

    Mr_Right.zip

    Make sure the database and all the jpgs (they're really small for the purposes of this example) are in the same folder

  3. #3
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,628
    You have images stored in database? Access has a 2gb size limit. Unless images are very small they will chew up this limit.

    The images are displayed in a subform? The subform is linked to the main form? Are you using an Image control to display images? The attachment field is a multi-value field. Are there multiple images in the attachment field? If so, is the subform RecordSource a query that expands the attachment field entries to multiple records?
    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
    mr_right is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Mar 2013
    Posts
    11
    Hello rpeare,
    This is great.
    This is what i want to to do. Could it be possible to to have a button or can double click the image to open in picture manager?
    Because sometimes i send those photo as an attachment to email.

  5. #5
    mr_right is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Mar 2013
    Posts
    11
    Hello june7,
    Good day!
    My images are stored in database. (i use attachment method not link and it is a multiple images).
    I use componentstbl as subform.
    Thank you for the "2GB size limit" info. I still don't know that.
    Thank you guys.
    This is a link for my database.
    https://www.box.com/s/989yvgsiin9bdfwfu0cn

  6. #6
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,628
    Clicking on the image triggers a little button menu above the image with Forward and Back buttons and a button to open attachment manager. Right click opens a shortcut menu with the same options.

    Not sure this behavior can be programmed on custom buttons. Can't find anything.
    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
    mr_right is offline Novice
    Windows 7 32bit Access 2007
    Join Date
    Mar 2013
    Posts
    11
    I will figure it out.
    BTW, thanks for your help.

  8. #8
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    As far as email goes, are you mailing more than one image per email? Or are you just emailing one image at a time. Do you want to email all images related to a specific construction? if so you can do that with code as well, you don't need to open any other application other than Access.

  9. #9
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,628
    I don't think opening the image in external app will aid in emailing the image. I have doubts can include image from attachment field in email with the SendObject method unless the image is in a report. Then if you want all the images for each record to show the report RecordSource must be a query that expands the attachments to individual records.
    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.

  10. #10
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    I wasn't thinking of SENDOBJECT to do the emailing (http://www.granite.ab.ca/access/email/sendobject.htm see this for sendobject's limitations). I was thinking more of using OUTLOOK commands to build the email, I was just assuming since he's using access he's also using OUTLOOK.

  11. #11
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,628
    I think the issue with emailing the attachment images is the same. Can't be just table or query, must be report with attachment field expanded to multiple records.
    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.

  12. #12
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    Oh I think we're thinking about how to send the email differently. I am thinking that he wants to send an email to a client with a picture, say, of the final product and all the component pieces. You can do that by sending multiple attachments rather than trying to send a query/table. I wasn't even considering that he might want to send a copy of the form (for instance) to someone.

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

Similar Threads

  1. Get current record when open an excel file
    By majinon2012 in forum Programming
    Replies: 1
    Last Post: 06-12-2012, 10:32 AM
  2. Buttons on form to navigate through records
    By emilyrogers in forum Forms
    Replies: 2
    Last Post: 07-19-2011, 10:17 AM
  3. Command buttons to Open Forms
    By Ace Pioneer in forum Access
    Replies: 1
    Last Post: 11-30-2010, 06:32 AM
  4. Replies: 2
    Last Post: 03-25-2010, 12:11 PM
  5. Open form to current record
    By rbpd5015 in forum Access
    Replies: 1
    Last Post: 08-28-2009, 01:53 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