Embedded images in report-records while using SQL in recordsource


Hi, I've got a strange issue where i've been searching for some time without finding a good answer:

I have a database with embedded illustrations which I use to make sparepart lists. The records are all retrieved and nicely ordered inside a report.
In the past worked a lot with queries and this went just fine. Now recently I started to work with VBA to automate and speed up some things.
Now I make reports via SQL with the correct records (just like i had with the integrated queries before in the recordsource), however I noticed, the images are not visible in the reports

I narrowed down and figured out the following:

When I link the recordsource of an (illustrated) report to a query inside the report's properties, the images in my report (which are embedded images per record) are visible.
When however, I use an SQL statement inside the recordsource, which is exactly corresponding to the queries I used before, the images are NOT visible in my report

Does somebody knows what I should do to obtain my images in my reports especially when I want to work with SQL instead of queries (inside my report?)
I really would like to work with SQL as can easily create the correct statements/code in vba...

Thank you!


Sponsored Links:



Hello, I'm a new user to access and I have a poor knowdledge in scripting with visual basic. After many searches I managed to find this awesome forum where in the future I could learn a lot of stuff about creating "solid" Access Databases.

Due to the fact I'm in the need of a database of the objects I buy/sell in my shop I started creating my own database with Access 2007. Unfortunately the templates available with Access 2007 couldn't provide me much help, so I had to build a database from scratch. I've had a few hard weeks but finally I'm starting to understand many of the things that run an Access Databases.

Unfortunately I came up with a problem managing images in my database. As I've figured out, and read amongst various threads here, embedding images in a database with Access isn't a good thing (Especially if the database needs to hold 1000+ photos).

I searched the forums and found that many users asked already for this but due to my knowdledge with scripting (and the fact of being still a new user with Access2007) I can't figure out a way to implement un-embed images in my database.

My database is almost finished, I need to polish the masks a bit as well as a few other stuff but I still have to deal with this problem with images.

I wanted to ask if anyone here was kind enough to provide me some help by converting my "embed image fields" into unembed ones.

I'll explain here how the database manages images:

Table Acquisto keeps records of the object I sell and has an Attachment field called "Immagine". This field stores the embed image files.

The mask called "mask_aggiungi" add new records to the Table Acquisto and has a dedicated box for the Immagine attachment field. After adding the attachment file, it displays the picture uploaded in the database.

The following masks and reports read and edit the Immagine attachment field:

mask_visualizzamod
repGaranzia

Basically the work that has to be done is to delete the Immagine attachment field and replace it with a normal text field (that could still be named Immagine) that will include the Image URL of each record. A script (and here's where I am absolutely out of knowdledge and need help) reads this new Immagine text field and displays in the Immagine boxes a "preview" of the image URL I've given to each record.

Also one last thing. In order to implement this it would be good for me to create a folder which would store my image files and that would always be the same (and never change it's path). Is it possible to only insert the Image name (and extension) given the fact that the path (and folder) would never change?

Example:

Immagine field:
filename.jpg (the database already knows the folders where to look after the file by default ex. c:documentsimages)

instead of

Immagine field:
c:documentsimagesfilename.jpg


Anyone could help me do this? I'm attaching to this post the database I've created.

Thanks a lot in advance,

Best Regards

Filippo




I am a total novice with MS Access (2007) coding and I am struggling with trying to come up with a way to enable an insurance adjuster to add multiple images to any record and to generate a report that includes however many images that are associated with a given record. Can anybody help me out with this by offering strategies, examples, or informational references?

Because there may 60+ pictures associated with a single claim record my design will need to involve links to pictures residing outside the database in a folder. Each computer on the network must be able to be directed to the link addresses properly. Also, the reports will need to have a caption under each picture.




I am having trouble with exporting images in reports inMicrosoft Access 2010. I am using MicrosoftSarepoint to link with access. End usersenter data in a SharePoint list which creates a table. Sharepoint can only import images through a “Attachments”field. End users routinely attach 3 or 4photos to an individual record.
I use Access 2010 to import the data from the SharePointlist, which appears as a simple table in Access. All images appear in an attachments field. Web databases in access are only allowed 1 attachments field that can contain multiple attachments (various photos in my case).
I want to create a report that can display images in the attachmentfield. Currently, Access in only pullingthe first image in the “attachments” field. When I add the attachment field multiple times in the same report record,it pulls the same photo. I need to knowhow to tell the attachment field to display different images in the report.
Can anyone help with this?
Thanks.




Hi,
Can anyone point me in the right direction?

I am trying to link images to a report that are different for each record.
I have tried making the data field type "OLE object" and linking the image to the report, but I have reached a 1 Gigabyte size of database and no more data can be added.

I can list the paths to the images O.K. in the data field but am having difficulty in viewing the images in the report. I keep seeing the same image.

I have followed microsoft's help files but I can only see the same image in every record not different images.

Any ideas?

Russell




Hi folks,

I'm attempting to output a report into 'rtf' format which has two embedded images in the header,

When I output the report both images have been stripped from the report, the same happens if I try to output it as 'htm' format,

Please help as to why it would do this,

My gut instinct is security or an option somewhere but I haven't found it yet,

Many thanks all




I'm learning fairly steadily with access (thanks in no small part to this forum!). I have made my own database for work use which works fine relating images to specific records - linked of course to keep the DB size down (one image per report).

The problem I'm encountering now is another database; the main DB of my company in fact. It still relates to images/reports though.
The DB is built so that users can embed images into a form which then show on a report. Regular 'spring cleaning' removes images which are no longer required, which is followed by compact and repair, which keeps the DB size down.
The problem I have is that I have a particular part of my work which requires many, many, many images as part of the same report. I've tried embedding the images once, only to find the DB seems to max out at 2GB and fails to display more than 75% of the images.

I am playing with a backup copy of this DB in order to change the image on the form from embedded to linked - this has worked okay and obviously reduces DB bloat.

However, when trying to print preview/print the report, the DB slowdown is unbelievable - so much so i'm considering going back to embedding/doing regular compact repair and having to do this particular report in stages. (I'm beginning to understand why it was built this way in the first place now!!)
When previewing the report, a message box is displayed showing info for each pic - this only reaches about 40% of the total number of images before an error message appears (no details, sorry!).

Is this just due to physical/virtual memory on the chosen PC? Or can some nice person on this forum give any help with Access? (2003 BTW).

Sorry for the length of the above - I needed to explain it properly so I could understand it

swifty




Hi there

How can I show images (one image to one record) in my report??

This images is placeret in my database as text object, and I use VB-code simular to the one in "Northwind exemple database" to show them in my formular.
I dont´t want to use the images as a Ole-object, becouse it will increase the size of my database, and data access page don´t support ole-object.

So...how do I get my pictures in to my report??

Venlig hilsen
alrun




Hey,

I have some images that are stored as file paths in my database (different for each record).

I want to let them appear on my report, and this works (with an image control and some vb code), but with some problems.

1) The image looks terrible, I think this is some kind of conversion to bmp (from jpg), but I'm not sure. And as i use vb and file paths with an image control, I don't see why the image should be converted.

2) Also, everywhere I search for a solution to show images in a report, it's always only on print view. Is there a way to display them on normal report view?


Thanks seba




I’m struggling with what should be a simple problem. Each record in my database includes a field containing a hyperlink to an associated image file. The hyperlink is a relative address since the whole system is used from time to time on different computers.
Displaying these images in Forms and Reports requires that the image control contain the absolute path. Therefore I can’t set the image control directly to the link field in the record. I’ve got round this for Forms by using an Event Procedure on the After Update event that calls a decoding routine that, amongst other things, uses VBA to find the full path to the current folder, as well as performing some other checks.
Reports are a different matter, there being no equivalent at the record level to After_update and similar events. One helpful suggestion on the web is to add the path to the database files in the underlying query. That will work well for one computer but I don’t know any dynamic way to load the current path into a query.
Is it possible to do this? Alternatively could someone suggest a workaround?
I’m using Office 2010 under Win 7.




hi
i have created a form bringing together 3 queries. one of the queries contains images the other 2 queries are text/data information.
i am now creating a report to print out the queries. each query is made into a report and then combined with a main report [2 of the queries are subreports]. the code i have used to link the images so that i get a unique image with every record is

me.[cempic2].picture = me![combined_mage_path]

however when i print the report if the record contains more then 1 image i get the following [screenshot 2].
what i need to do is to limit the image print out for each record to the first image only. the only common naming criteria for all my images is 001.jpg, 002. jpg and so on
what i need to do is to show only the image for each record that ends with the criteria *001.jpg. how would i do this in VB?
thanks




Hello Everyone,

I am hoping this doesn't require dismantling the report I've generated. Here is my situation. I have a report for which I wrote a subroutine that filters the record source. To avoid having to retype the SQL statement selecting the fields I had built into the initial report, I simply copied and pasted the SQL statement that was the original record source (minus the WHERE clause that my code adds to filter the records). However, I apparently hit an extra key that changed the statement. Now, whenever I am in Design View and I try to edit the record source I get the following error message:

"Missing ), ], or Item in query expression 'GandHtracker.[SMART ID] = PartInfo.[SMART I'."

Now I can clearly see what it is that needs to change and I know exactly what it should say. The problem is that after I click "Okay" I do not get the query in either the QBE or SQL format. The above issue doesn't seem to be causing any problems at present since my filtering code replaces the record source SQL statement with one that is correct, but I'd like to clean it up just the same. Anyone know a sneaky way to get at the SQL code?

Thanks!




I have an image in a report which is there on screen but doesnt print on my inkjet. Have tried bmp, jpg, linked and embedded, nothing works.
It prints on my laserjet, however. Even so, Im sure it's not the printer settings as I print images all the time.

any ideas gratefully received!




Hi! Let me describe my situation first, just to give you guys a clear view of what I'm doing. My database has links to upto 6 image files(each taking up the whole page, 8.5 by 11), per record. I'm trying to provide an interface for my users to view the image files, so I made a report, which contains 6 image files which will refresh to the images in the table (the link to the image files are passed on load). The problem isn't how to get the image file links in. It's just that it seems that there's a 23 in limit to the length of the access report. Is there any way to bypass that? Or do you suggest an alternative way to getting those upto 6 images into a report? Thank you!!




I have a report that is a customer quotation, which is based on a query. In the query, once of the fields pulled is fldSIGNATURE, which is a link to the path of an image on my network of the quote originator's signature. I would like to be able to print out the report based on this image. I have a table that has the paths to the files. Is there a way to update the image in an image frame when the report changes from record to record?

Any suggestions? I appreciate any help or direction of where to find out how to do this.

Thanks,

Brad




i have a series of thumbnail bitmap images that are pretty damn good quality when viewed in paint or any other program but as soon as i put them into a report their quality is awful to the point i cannot hand this to a customer like it is. the image size is not changing, its just awful looking, like its changed from 32 bit to 8 bit or something or less. When i use the same images in a form it is perfect, no problems.
What is the problem with reports? how can i fix it??




Hello,

I am new to Access 2007 and I have a number of reports with three images in the header (2 logos and a banner). However, this has bloated by database in a huge way.

I've been reading and searching and it seems the solutions is to "link" the images versus embed them. But, for the life of me, (and I'm sure this is such a simple solution) I cannot figure out how to link the images in the reports.

It is the same three images used as the header for every report.

Please help and apologies if this has already been addressed. I did do a search and could not find my solution.

Thank you!




I searched through the posts looking for a way to change a form or report's record source using a macro. I found several discussion on how to do this with VBA code (see below) but none using a macro to do this.

Basically I want to be able to click on various buttons on a form, with each button opening the same form but with differenent recordsource. I do not want to do this with VBA unless it is the only way to do this.

Is it possible to do this with a macro? I am using Access 2007.

Thanks in advance,

newbie



http://www.access-programmers.co.uk/...t=recordsource




Hello everyone,
I have a few questions about using/writing SQL.

I would like to start programming in SQL. I am a Database Manager and I have a lot of reports that are in Text Files (these Text Files contain a lot of Necessary and UnNecessary data. I want to try and use SQL to format them and extract the needed data to create a professional report.

Can I use SQL to do this?

I know this might seem like a stupid question, but I have installed and configured MySQL Ver 4.1.7 and the MySQL Query Browser on my Windows XP machine. Windows (itself) basically done all of the installing and configuring...I just answered a few questions.

Now that it is installed and everything...how do you open it up to start programming / typing the MySQL code to import the text file and format it, etc?

I have not found a ExE file to click on and open. I have attached a screen capture of what the MySQL Query Browser is asking for. I just do not know what to enter into those fields.

Can someone tell me what I need to do next....PLEASE BE DETAILED...I want to make sure that I get it right the first time.

Also,
I have read a lot of posts that talk about creating code and connecting to the server...so now I have a few questions.

If I create a set of SQL code to import, format, and create a report of my data...can I do this (run this code) independently of any other server (outside of my own computer)?

In other words...Can I take this SQL code and make it an actual program/database that has, for example, an EXE/BAT/COM extension to run on any computer (independently)?

Could everybody please provide some input on this post. It will help other Newbies in the future.

Thanks

Bobby Howerton




Hey,

I want to store images in a text field and show them with vba on reports and on the forms (image control).
This all works, but I need to type the path to the images.

Is there a way to use a file picker for this, but still store it in a text field?

Thanks,
Seba