Re: File Copy / Save in Access: Is it Possible?
- From: Bob Quintal <rquintal@xxxxxxxxxxxxx>
- Date: 11 Jul 2007 14:19:25 GMT
Swinky <swinkelman@xxxxxxxx> wrote in
news:1184164977.080948.43730@xxxxxxxxxxxxxxxxxxxxxxxxxxx:
My manager threw out the gaunlet and I'm at a loss how toStart with the File dialog, you can upgrade to something more
accomplish this or if it's even possible within the Access
environment.
Challenge: While having Access open, locate a file on the
network, automatically make a copy of that file and
(automatically) save the copy in a specific folder on the
network. At the same time all this happens, a link is created
in the Access database to the copied file.
Challenge Comments: Each file will have a unique name & will
be in a different location (can be on desktop or network
location). To make it even more challenging, the file could
be an Outlook email (the process would then be to locate the
specific email in Outlook, copy it as a .msg file and store
the copy in a specific folder). It would be acceptable to have
two different control buttons (one for a file on the network &
the other for an email) to do the work
I found the API code to get the File Open/Save dialog box, but
that isn't exactly going to accomplish what I need to do. My
manager wants all of this to be automated using code (either
behind the scenes or with a Click & Drag dialog box if set up
properly to make it as easy as possible).
Can anyone tell me if any of this is possible and if so, how?
One more thing...I am a novice (I use that word loosely) at
VBA or ANY programming at all (I just bought the book "Access
2003 VBA Programmers Reference" to try to pick up VBA).
Possible solutions (in order of preference):
1. VBA code that will handle it all
2. Canned software designed to do this in an Access
environment 3. Hire a consultant to do the work (what would be
the scope & cost of doing this?)
4. No solution...it can't be done.
All ideas are appreciated.
sophisticated later.
Once you have a fully qualified filename, parse out the
extension, then use the filecopy statement to put that file in a
predefined directory, with a new name based on the record's
primary key (usually an autonumber) & the extension.,
e.g.
txtMyextension = mid(Fromfile,len(myfile) -3)
TxtMyPath = C:\dBdata\attachments\"
FileCopy Fromfile, txtMyPath & format(pk,"00000000") & "." &
txtExtension
Update the record in the table with the new name and extension.
Once you have that section working, you can experiment with
alternative methods of obtaining the fully qualified filename,
for example using the Outlook api..
--
Bob Quintal
PA is y I've altered my email address.
--
Posted via a free Usenet account from http://www.teranews.com
.
- Follow-Ups:
- Re: File Copy / Save in Access: Is it Possible?
- From: Swinky
- Re: File Copy / Save in Access: Is it Possible?
- References:
- File Copy / Save in Access: Is it Possible?
- From: Swinky
- File Copy / Save in Access: Is it Possible?
- Prev by Date: Re: Access 2003 Runtime questions
- Next by Date: Re: Report/Query showing multiple entries for unique item
- Previous by thread: File Copy / Save in Access: Is it Possible?
- Next by thread: Re: File Copy / Save in Access: Is it Possible?
- Index(es):
Relevant Pages
|