Selasa, 04 Oktober 2016

Re: [MS_AccessPros] Attachment field question

 

Jim-


So is the number in 1.pdf the value in [ID] or the value in Me.PolicyNo?

John Viescas, Author
Effective SQL
SQL Queries for Mere Mortals 
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
(Paris, France)




On Oct 4, 2016, at 7:00 PM, Jim Wagner luvmymelody@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:



John,

ID is an autonumber and the file names will be named after the auto number to associate the file with the ID

I just found out that all of the files will be saved as pdf's

For example the file will be named 1.pdf or 2.pdf
 
Jim Wagner


On Tuesday, October 4, 2016 9:45 AM, "John Viescas JohnV@msn.com [MS_Access_Professionals]" <MS_Access_Professionals@yahoogroups.com> wrote:


Jim-

What do the file names look like, and what is in [ID}?

John Viescas, Author
Effective SQL
SQL Queries for Mere Mortals 
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
(Paris, France)




On Oct 4, 2016, at 4:54 PM, Jim Wagner luvmymelody@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:



John,

I put it in your code and the projpath line is red.

 
Jim Wagner


On Tuesday, October 4, 2016 7:41 AM, "John Viescas JohnV@msn.com [MS_Access_Professionals]" <MS_Access_Professionals@yahoogroups.com> wrote:


Jim-

Try this:

Private Sub Command13_Click()
Dim ProjPath As String
ProjPath = "\\Afwfs\AF\Users\jwganer\My Documents\" & [ID] & "*" & Me.PolicyNo.Value"
Shell "C:\WINDOWS\explorer.exe """ & ProjPath & "", vbNormalFocus
End Sub

I am assuming [ID] is a control or field on your form.  Why do you want to stick an asterisk in the middle of it?

John Viescas, Author
Effective SQL
SQL Queries for Mere Mortals 
Microsoft Access 2010 Inside Out
Microsoft Access 2007 Inside Out
Microsoft Access 2003 Inside Out
Building Microsoft Access Applications 
(Paris, France)




On Oct 4, 2016, at 4:28 PM, Jim Wagner luvmymelody@yahoo.com [MS_Access_Professionals] <MS_Access_Professionals@yahoogroups.com> wrote:



Thank You Crystal. 

So I was thinking about what you said about linking the files elsewhere. So I tried to add the following to a command button in a testing database to be able to open a file based on the id of the record. They planned on scanning the document whatever it is and save it with the name of the record number. But the code is not working. can you help with the syntax. I am getting the error on the  Type Mismatch of the line for ProjPath. I have used this code before to open a folder, so I thought I could add just the file name. 

Thank You 
Jim

Private Sub Command13_Click()
Dim ProjPath
ProjPath = "\\Afwfs\AF\Users\jwganer\My Documents\&[ID]*" * " '& Me.PolicyNo.Value"
Shell "C:\WINDOWS\explorer.exe """ & ProjPath & "", vbNormalFocus
End Sub


Jim Wagner


On Monday, October 3, 2016 7:18 PM, "crystal 8 strive4peace2008@yahoo.com [MS_Access_Professionals]" <MS_Access_Professionals@yahoogroups.com> wrote:


Hi Jim,
it depends on how many attachments you have.  And yes, it does make the database bigger.  Another problem with attachments is that often the same file is duplicated in the database (well probably not pictures of employees, but I found only 30% unique files for reference documents in one of the databases I analyzed and took attachments out of) whereas if it was referencing an external file, it would just be another text field with the path and filename.
I generally create a directory below the back-end with all the referenced files so it is easy to move them along with the database and everyone can get the same file even if their paths are different.
respectfully,
crystal

~ have an awesome day ~

On 10/3/2016 4:59 PM, luvmymelody@yahoo.com [MS_Access_Professionals] wrote:
Hello all,

I was just given a new project on a database that I did not build. There is an attachment field on the form. I am not very familiar with that. I was always told that it bloats databases. Yet when I tested the process, it looked like the opening of the attached files where looking at a location in a folder. 

So the question is, does the attached field bloat the database and make the 2GB limit a quick reach in a very short time?

Thank You

Jim Wagner

















__._,_.___

Posted by: John Viescas <johnv@msn.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (9)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

Tidak ada komentar:

Posting Komentar