Store Company's logo

Leo_Polla_Psemata

Registered User.
Local time
Today, 13:25
Joined
Mar 24, 2014
Messages
364
Hi
Could we store in a table, few pictures, say company's logo, and then with dlookup function, use this picture in forms/reports?
This would save space and if logo or company changes, we just replace the data from table and we keep on using batabase.
What method should we use ?
 
You have already described the idea!

Use a standard file name such as CompanyLogo.png and a fixed location. Also make sure the logo is a fixed size (width/height)
Store the file & path in a settings table.
You can use a public function or tempvar to retrieve that value wherever it is needed.
Now place that image on your forms/reports as required.

If the logo is updated (or replaced for a different company), all your forms and reports will automatically be updated
 
the problem with logo's is they come in all different sizes, so if you change the image, chances are you'll also need to adjust the image control anyway (at least for legal documents such as invoices) and may need to adjust the position as well.

I would recommend not storing pictures within your database but keep in a 'logo' folder and populate that instead - and store in your table the path to the required logo.

But if you want to store in your table, use an OLE object field. I haven't used them for a long, long time but seem to recall that image quality is not particularly good
 
use Attachment field.
 
I agree with arnelgp, in a limited case like this, I'd say it's perfect for actually using the attachment-type column.
 
I disagree and not just because I avoid using attachment fields almost entirely.
If the logo is updated, then the attachment field record will need to be edited/replaced.

Storing the logo externally as described earlier makes it simple to replace the file & update the logo throughout the application
 
I disagree and not just because I avoid using attachment fields almost entirely.
If the logo is updated, then the attachment field record will need to be edited/replaced.

Storing the logo externally as described earlier makes it simple to replace the file & update the logo throughout the application
That's a good point, unless you actually want the database user to be the one to do that - in which case the attachment method seems more portable.

In my current 'day job' environment, I would also use the method of storing it in a network folder. But I know many people need to make applications that aren't overly reliant on access to a network folder - especially because that's a more dangerous place for configuration files to reside, as the same people with access to the folder storing the back end will have access to tamper with configuration files like this.

I see pro's and con's..
 
I've used the approach I described for almost 20 years.

When clients purchase one of my commercial apps with a license for multiple workstations (or a whole site), the program admin is provided with instructions on how to customise the apps for their own company/school. One of the items that can be customised is to replace the supplied logo with their own ensuring it is the same file name/path & dimensions. Individual users have no access to the network folders where the logo and other items are stored.

Even for apps purchased by individual users, a folder is supplied containing images used by the application. It is a trivial matter to replace the logo.

I see no advantages in using an attachment field for this purpose.
However if I did choose to do so, I would just place the logo in the image library so users could replace it with their own
 
Last edited:
Yes I'm fully aware of that which is why I started the final sentence with "However if I did choose to do so...."
 
I use logos in several apps. In all cases, I store the path rather than the image. If I were going to store the image because there are only a few of them, I would NOT use an attachment field because that data type is not supported by SQL Server or other RDBMS. I would just store it as a blob.
 
Hi, many thanks for input.
After tried several methods, i found that, an image from library, right click, replace, you can chose and save another image , then this new image,will replace the old one from all previous form and report areas it was sitting. The reason I want to save inside access is because it is stored in a memory stick which i move in three different work stations. Storing in a path would make things a bit more complicated. It is not only the "logo", in several letters invoices etc, i need letter header footer etc.
 

Users who are viewing this thread

Back
Top Bottom