Solved

.ADP ACCESS PROJECT - Is it possible to create a form with an attachment button?

Posted on 2013-11-16
6
505 Views
Last Modified: 2014-01-22
I would like on my form to have an attachment button that can store .tif / .pdf / .jpg / .gif  in the SQL DB

Is this possible in an access database connected to SQL SERVER 2008 running as .ADP access project?
0
Comment
Question by:Dale Massicotte
  • 3
  • 2
6 Comments
 
LVL 24

Expert Comment

by:Bitsqueezer
ID: 39654286
Hi,

you cannot use the native attachment functions of Access as this is a ACE-only feature. But you can of course use the varbinary(MAX) datatype of SQL Server to store any kind of binary file into a column of a table in SQL Server.
I recommend to use an own table which holds such attachments and not add a varbinary(MAX) column to your normal tables because that will slow down the performance a lot. Using an own table has the advantage that you need the attachments only when the user wants to download one.
If possible you should consider to better use a separated fileserver to store the files and to present a link to the file in the database, otherwise your database size will grow very fast.

Cheers,

Christian
0
 
LVL 38

Expert Comment

by:Jim P.
ID: 39654470
I agree with Christian; you do NOT want to store binary objects inside a DB. Store pointers to them on disk.

Additionally the ADP support effectively ended with Access 2003, even though they will still work with newer versions of Access.
0
 
LVL 24

Expert Comment

by:Bitsqueezer
ID: 39654504
Hi jimpmen,

to be exact: In A2013 ADPs were removed from Access. But it is still possible to work with ADPs normally up to A2010 with SQL Server up to 2008. I personally also prefer to use ADPs instead of ACCDBs because of the JET/ACE in between which makes it really harder to work with SQL Server.
To avoid problems with updating frontends I use a terminal server which holds the A2010 runtime frontends so the user can install on his machine whatever he likes and the database frontend will never have a problem unless the database server will not be upgraded to a newer version.

Cheers,

Christian
0
U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

 
LVL 38

Assisted Solution

by:Jim P.
Jim P. earned 200 total points
ID: 39654544
Christian,

I meant that support went away in the sense MS never created an AccDP standard that is like the mdb to AccDB change.

I always shied away from ADPs because of all the networking issues. The companies I have worked for have always had segmented networks that made it harder to get good connectivity from workstations to the SQL Server(s).

Another difference is that most of my stuff is ETL tasks, not OLTP.

So if the database is designed correctly it is easy to put data into a DB with DAO or ADO or extract to an import standard and then get it imported into another DB.

Regardless, to the asker's question. The storage of a binary data in the DB is never suggested. The only way I would support it is something like the logo.jpg for a report or a single form.pdf to be sent with an e-mail. Beyond that it should never really be contemplated.
0
 

Author Comment

by:Dale Massicotte
ID: 39687264
jimpen & Bitsqueezer

do you have any code samples of how I might be able to use a pointer (saving to a specific network share folder) via CMD BUTTON.

For example if there  is no file stored the CMD button would prompt user to save file and would actually save the pointer.

If the pointer was stored then the CMD button would retrieve the image file via the pointer that was stored.

Our customers on-line would then be able to retrieve the document via .aspx page
0
 
LVL 24

Accepted Solution

by:
Bitsqueezer earned 300 total points
ID: 39687395
Hi,

Access can store and present a URL as hyperlink in a normal text field. That's all you need to do and then present this URL to the online users, if they click it it will download the file from this URL (the user must of course have access to it).

No code needed for this functionality.

Cheers,

Christian
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In a multiple monitor setup, if you don't want to use AutoCenter to position your popup forms, you have a problem: where will they appear?  Sometimes you may have an additional problem: where the devil did they go?  If you last had a popup form open…
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question