Access World Forums

Access World Forums (https://www.access-programmers.co.uk/forums/index.php)
-   Tables (https://www.access-programmers.co.uk/forums/forumdisplay.php?f=7)
-   -   Unable to add attachments in linked table (https://www.access-programmers.co.uk/forums/showthread.php?t=305367)

RogerCooper 06-05-2019 11:21 AM

Unable to add attachments in linked table
 
I have found that I can add attachments in the attachment field only if it is native table of the database, but I can't if it is a linked table. Is this a feature of Access or is there a way of doing it?

I can always have the users work with the database containing the table, but it would be easier if there was a linked table.

theDBguy 06-05-2019 11:23 AM

Re: Unable to add attachments in linked table
 
Hi. Without testing it, I am not sure this is correct. How exactly were you attaching the files to the linked table?

Micron 06-05-2019 01:45 PM

Re: Unable to add attachments in linked table
 
you are aware that attachments in Access tables can cause you to quickly reach the db size limit? Often the better method is to store the attachment file path in a table and just let the user call it from some user action such as a button click. The file or folder picker is all that's needed to store/retrieve files and store the path.

June7 06-05-2019 01:51 PM

Re: Unable to add attachments in linked table
 
It is definitely possible. Not a problem for me.

Mark_ 06-05-2019 05:43 PM

Re: Unable to add attachments in linked table
 
Roger,

I'll second Micron's post. Also allows you to manipulate the attachment with the program it is intended to work with. Means you can have a word document, open it in word, and allow your end users to update if needed.

RogerCooper 06-21-2019 11:51 AM

Re: Unable to add attachments in linked table
 
Quote:

Originally Posted by Micron (Post 1626110)
you are aware that attachments in Access tables can cause you to quickly reach the db size limit? Often the better method is to store the attachment file path in a table and just let the user call it from some user action such as a button click. The file or folder picker is all that's needed to store/retrieve files and store the path.

The attachments are image files that need to be included printed documents that are sent with shipments. It works, except for the annoyance that you need to edit attachments in the original database.

Micron 06-21-2019 12:19 PM

Re: Unable to add attachments in linked table
 
If the documents are Access reports, you still don't need to store the images. As noted, works for someone else as a linked table, but I can only comment with respect to my belief that the practice is to be avoided if at all possible, so I cannot offer a solution. Sorry.

RogerCooper 06-24-2019 03:36 AM

Re: Unable to add attachments in linked table
 
The documents aren't Access reports, they are image files. They need to be printed automatically, not by a user sitting there and selecting them manually. And how I can trust that files external to my database will be there when needed.

The_Doc_Man 06-24-2019 06:20 AM

Re: Unable to add attachments in linked table
 
Quote:

And how I can trust that files external to my database will be there when needed.
Roger, let me ask this question in response. Do you have an environment where you cannot trust people to not screw around with files that aren't supposed to be theirs?

The way most of us do this is that we set up a folder for the shared back-end database. Then with the back-end file in place, we create a child folder with an appropriate name. We read the contents of the .Connect string on a back-end-resident table, which gives us the device:/path/name.type sequence, and we can trim out the name.type part, tack on the sub-folder name to the device:/path/ string, and build a proper fully qualified file spec for whatever we are about to put into that folder - like one of your images. When storing that image for the first time, we also store the spec as a string. The difference is that images take dozens of KB but a file spec rarely takes more than 128 bytes unless you have some really abominable file or folder naming conventions.

When we want to display an image associated with a record, we load the spec to the property .Image in the appropriate image control using VBA in the appropriate section of the report that contains the other stuff we needed to see. You don't ever let users see that level of interaction, though. You hide everything behind forms so that nobody gets to "look inside the box" of your app.

theDBguy 06-24-2019 06:53 AM

Re: Unable to add attachments in linked table
 
Quote:

Originally Posted by RogerCooper (Post 1628280)
The attachments are image files that need to be included printed documents that are sent with shipments. It works, except for the annoyance that you need to edit attachments in the original database.

Hi Roger. As June already said, this should not be a problem, and I think he's right. You should be able to edit attachments in linked tables.


All times are GMT -8. The time now is 12:28 AM.

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World