Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / March 2007

Tip: Looking for answers? Try searching our database.

jpg from clipboard to image field in Access 2003

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Charles GUELDRE - 30 Mar 2007 21:42 GMT
How to paste programmatically  a picture (jpg) from the clipboard to an
image field in Access 2003?
Bill - 31 Mar 2007 00:49 GMT
With the desired field haveing the focus:

try: RunCommand acCmdPaste

Bill

> How to paste programmatically  a picture (jpg) from the clipboard to an
> image field in Access 2003?
Charles GUELDRE - 31 Mar 2007 08:29 GMT
It's what I try first but : Microsoft Access can't move the focus to the
Image Control.

I have tried with :
me.Image0.setfocus
and
docmd.gotocontrol "Image0"

> With the desired field haveing the focus:
>
[quoted text clipped - 4 lines]
> > How to paste programmatically  a picture (jpg) from the clipboard to an
> > image field in Access 2003?
Bill - 31 Mar 2007 11:31 GMT
Hummmm! I tried to paste the clipboard in the OnClick event
of an image control and that failed with "paste not available now"
message.

try searching at: http://www.mvps.org/access/

Bill

> It's what I try first but : Microsoft Access can't move the focus to the
> Image Control.
[quoted text clipped - 12 lines]
>> > How to paste programmatically  a picture (jpg) from the clipboard to an
>> > image field in Access 2003?
Daniel - 31 Mar 2007 11:42 GMT
I hope that you are not wanting to embed the images in your database!  This
will cause database bloating and is typically bad practice.  See,

http://www.mvps.org/access/forms/frm0030.htm

What you should be doing is storing the path/filename of the images.  Once
again, refer to the link provided above

Post back if you need more info.
Signature

Hope this helps,

Daniel P

> How to paste programmatically  a picture (jpg) from the clipboard to an
> image field in Access 2003?
Charles GUELDRE - 31 Mar 2007 15:32 GMT
What my user wants to do is for example :
copy an image from a Word doc( or other source) and paste it into a image
field in a form.

> I hope that you are not wanting to embed the images in your database!  This
> will cause database bloating and is typically bad practice.  See,
[quoted text clipped - 12 lines]
> > How to paste programmatically  a picture (jpg) from the clipboard to an
> > image field in Access 2003?
Daniel - 31 Mar 2007 16:04 GMT
You need to do some automation in that case.  Temporarily copy the image to a
temp table of sorts, then using code copy the images to a set location and
create only a link (path/filename) within the database.  Then as each image
is processed, delete it from the temp table.

Do not hold the actual image(s) in your db!!!!
Signature

Hope this helps,

Daniel P

> What my user wants to do is for example :
> copy an image from a Word doc( or other source) and paste it into a image
[quoted text clipped - 17 lines]
> > > How to paste programmatically  a picture (jpg) from the clipboard to an
> > > image field in Access 2003?
Bill - 31 Mar 2007 19:21 GMT
As Daniel has already pointed out, you'll need an intermediate
file. But, as Daniel also pointed out, you do not want to store
images in your database.

I have an application wherein the user has scanned or otherwise
obtained an image on the clipboard. I direct the file naming from
within the hosting form's class module where the user stores the
image. The application's tables contain the name of the file containing
the image and is correlated to the autonumber of the corresponding
record. E.g., c:\AppFolder\AppImages\Im000438.jpg.

My form has a command button, "Import Image", that creates an
empty jpg file and opens whatever graphics editor the user has
available. The user pastes his/her image into the current graphic
window and saves and closes the current graphic window. When
all other "required" information is completed, I save the pending
record into the database, obtain the autonumber assigned and
rename the image file accordingly, all the while poised to purge
everything if the user aborts the operation.

The application necessarily has "user installation parameters" that
are contained in one of its tables that, amongst other things,
specifies to the application user chosen folder names and what
graphics and/or text editors the application is to use.

Post back if you have any questions.

Bill

> What my user wants to do is for example :
> copy an image from a Word doc( or other source) and paste it into a image
[quoted text clipped - 18 lines]
>> > How to paste programmatically  a picture (jpg) from the clipboard to an
>> > image field in Access 2003?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.