By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,775 Members | 2,658 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,775 IT Pros & Developers. It's quick & easy.

file attachment in vb 6 and access 2000

P: n/a
Hi

This is my second try... any takers?

I have an application that is up and running. Everything is working
perfectly. The application is written in VB 6 SP5 using Access 2000 to
store the data.

The users would now like to attach files (Word, Excel, etc) to the
records. I have no idea how to go about this :o( I am a Lotus Notes
programmer and in Notes I would have created a RichText field and they
could load and edit their attachment in it. How do I do this in VB?

I have tried to add a RichTextBox. When I drag and drop documents into
the RTB all that happens is I get a link to the origional document.
What I want is for the file to get copied into the RichTextBox. When
the user drags it out it gets deleted. When they double-click it gets
edited. Surely there is a control that has these basic functions?

Any help would be appreciated - just a pointer in the right direction
would be great ;o)

Thanx in advance
Ursus
Nov 12 '05 #1
Share this Question
Share on Google+
7 Replies


P: n/a
[posted and mailed]

ur*************@hotmail.com (ursus) wrote in
news:5b**************************@posting.google.c om:
Hi

This is my second try... any takers?

I have an application that is up and running. Everything is
working perfectly. The application is written in VB 6 SP5
using Access 2000 to store the data.

The users would now like to attach files (Word, Excel, etc)
to the records. I have no idea how to go about this :o( I
am a Lotus Notes programmer and in Notes I would have
created a RichText field and they could load and edit their
attachment in it. How do I do this in VB?

I have tried to add a RichTextBox. When I drag and drop
documents into the RTB all that happens is I get a link to
the origional document. What I want is for the file to get
copied into the RichTextBox. When the user drags it out it
gets deleted. When they double-click it gets edited. Surely
there is a control that has these basic functions?

Any help would be appreciated - just a pointer in the right
direction would be great ;o)

Thanx in advance
Ursus

Why not simply carry the files' path as a string variable on
your Access DB. That way, when you double click the path name
you can read your file into the RTB.
--
Robert L. Berman
Database consultant
Vulcan Software Services

Nov 12 '05 #2

P: n/a
Hi Robert,

thank you for your answer but we want to keep the file in the database
and not in the file system.

Basically what we want is a file repository! The documents are created
externally and the just stored in the Access DB.

Any other ideas?

Ursus


Robert Berman <No***********@earthlink.net> wrote in message news:<EP*******************@newsread2.news.atl.ear thlink.net>...
[posted and mailed]

ur*************@hotmail.com (ursus) wrote in
news:5b**************************@posting.google.c om:
Hi

This is my second try... any takers?

I have an application that is up and running. Everything is
working perfectly. The application is written in VB 6 SP5
using Access 2000 to store the data.

The users would now like to attach files (Word, Excel, etc)
to the records. I have no idea how to go about this :o( I
am a Lotus Notes programmer and in Notes I would have
created a RichText field and they could load and edit their
attachment in it. How do I do this in VB?

I have tried to add a RichTextBox. When I drag and drop
documents into the RTB all that happens is I get a link to
the origional document. What I want is for the file to get
copied into the RichTextBox. When the user drags it out it
gets deleted. When they double-click it gets edited. Surely
there is a control that has these basic functions?

Any help would be appreciated - just a pointer in the right
direction would be great ;o)

Thanx in advance
Ursus

Why not simply carry the files' path as a string variable on
your Access DB. That way, when you double click the path name
you can read your file into the RTB.

Nov 12 '05 #3

P: n/a
ur*************@hotmail.com (ursus) wrote in
news:5b**************************@posting.google.c om:
Hi Robert,

thank you for your answer but we want to keep the file in
the database and not in the file system.

Basically what we want is a file repository! The documents
are created externally and the just stored in the Access
DB.

Any other ideas?

Ursus


Robert Berman <No***********@earthlink.net> wrote in
message
news:<EP*******************@newsread2.news.atl.ear thlink.net
...
[posted and mailed]

ur*************@hotmail.com (ursus) wrote in
news:5b**************************@posting.google.c om:
> Hi
>
> This is my second try... any takers?
>
> I have an application that is up and running. Everything
> is working perfectly. The application is written in VB 6
> SP5 using Access 2000 to store the data.
>
> The users would now like to attach files (Word, Excel,
> etc) to the records. I have no idea how to go about this
> :o( I am a Lotus Notes programmer and in Notes I would
> have created a RichText field and they could load and
> edit their attachment in it. How do I do this in VB?
>
> I have tried to add a RichTextBox. When I drag and drop
> documents into the RTB all that happens is I get a link
> to the origional document. What I want is for the file
> to get copied into the RichTextBox. When the user drags
> it out it gets deleted. When they double-click it gets
> edited. Surely there is a control that has these basic
> functions?
>
> Any help would be appreciated - just a pointer in the
> right direction would be great ;o)
>
> Thanx in advance
> Ursus
>

Why not simply carry the files' path as a string variable
on your Access DB. That way, when you double click the
path name you can read your file into the RTB.


Ursus,

Check out APPENDCHUNK and GETCHUNK. I would think 1.2GB would
be sufficient to hold what you need. Look in VB HELP rather
than the ACCESS help file.

--
Robert L. Berman
Database consultant
Vulcan Software Services

Nov 12 '05 #4

P: n/a
ur*************@hotmail.com (ursus) wrote in message news:<5b**************************@posting.google. com>...
Hi Robert,

thank you for your answer but we want to keep the file in the database
and not in the file system.

Basically what we want is a file repository! The documents are created
externally and the just stored in the Access DB.

Any other ideas?

Ursus

The problem with storing the files inside the DB is that your DB is
going to get very big pretty fast. When it goes bang, you risk losing
all your files. You might want to read Larry Linson's FAQ on storing
image files, as this is similar in a some ways:
1. you want to be able to manipulate the files/search for them
2. you want to view them from your DB.
Nov 12 '05 #5

P: n/a
ur*************@hotmail.com (ursus) wrote in message news:<5b**************************@posting.google. com>...
Hi Robert,

thank you for your answer but we want to keep the file in the database
and not in the file system.

Basically what we want is a file repository! The documents are created
externally and the just stored in the Access DB.

Any other ideas?

Ursus

The problem with storing the files inside the DB is that your DB is
going to get very big pretty fast. When it goes bang, you risk losing
all your files. You might want to read Larry Linson's FAQ on storing
image files, as this is similar in a some ways:
1. you want to be able to manipulate the files/search for them
2. you want to view them from your DB.
Nov 12 '05 #6

P: n/a
The sample databases illustrating three approaches for handling images in
Access are at http://accdevel.tripod.com. Similar approaches might be used
to handle other types of file, except that a Bound OLE frame is likely to be
required for some types of document. You can't, of course, display just any
document in an Image control -- but the _storage_ techniques apply.

Larry Linson
Microsoft Access MVP

"Pieter Linden" <pi********@hotmail.com> wrote in message
news:bf**************************@posting.google.c om...
ur*************@hotmail.com (ursus) wrote in message

news:<5b**************************@posting.google. com>...
Hi Robert,

thank you for your answer but we want to keep the file in the database
and not in the file system.

Basically what we want is a file repository! The documents are created
externally and the just stored in the Access DB.

Any other ideas?

Ursus

The problem with storing the files inside the DB is that your DB is
going to get very big pretty fast. When it goes bang, you risk losing
all your files. You might want to read Larry Linson's FAQ on storing
image files, as this is similar in a some ways:
1. you want to be able to manipulate the files/search for them
2. you want to view them from your DB.

Nov 12 '05 #7

P: n/a
ur*************@hotmail.com (ursus) wrote in message news:<5b**************************@posting.google. com>...
Hi Robert,

thank you for your answer but we want to keep the file in the database
and not in the file system.

Basically what we want is a file repository! The documents are created
externally and the just stored in the Access DB.

Any other ideas?

Ursus


Ursus,
I agree with Robert. You could do what you're proposing, I guess, if
you use SQL Server. I don't think Access would be terribly stable for
that. Once it gets big, performance would probably not be very
pretty... What happens if you database crashes?
Nov 12 '05 #8

This discussion thread is closed

Replies have been disabled for this discussion.