473,804 Members | 3,049 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Adding Images to Reports from File Paths

Hi,

I'm trying to add images to a report, pointing to a field in a query
containing the file path (a combination between a string value and an
existing field). There's nothing wrong with the path, but for some
reason I get a message saying it can't find the field "IMAGE_PATH ".
I'm using the following code, which should work:

Me!ImageFrame.P icture = Me.IMAGE_PATH.V alue

The field is in my list and I even get it popping up when coding, as a
valid field to use.

What am I doing wrong? Should I be pointing at the query differently?

Cheers

Dean

Aug 7 '07 #1
3 5045
In Reports, Access is "smart" and even though the Field may be in the Record
Source, if it is not the Control Source of a Control, it will not be brought
along at runtime. Using it in VBA code, as you are, is not enough. Add a
Control to your Report, bound to IMAGE_PATH, and set its Visible property to
No if you don't want it to be seen. (Don't name the Control the same as the
Field, IMAGE_PATH, so as to avoid any possible confusion -- txtImagePath
should work nicely.)

I'll wager you won't have the same problem after that. If you do, refer to
that Control, instead of the Field itself.

Larry Linson
Microsoft Access MVP
"Dean" <de**********@y ahoo.comwrote in message
news:11******** **************@ g12g2000prg.goo glegroups.com.. .
Hi,

I'm trying to add images to a report, pointing to a field in a query
containing the file path (a combination between a string value and an
existing field). There's nothing wrong with the path, but for some
reason I get a message saying it can't find the field "IMAGE_PATH ".
I'm using the following code, which should work:

Me!ImageFrame.P icture = Me.IMAGE_PATH.V alue

The field is in my list and I even get it popping up when coding, as a
valid field to use.

What am I doing wrong? Should I be pointing at the query differently?

Cheers

Dean

Aug 7 '07 #2
Hi Larry,

Thanks for the reply! I got this working with your suggestion, BUT
(yes, you just knew this was coming...) I get a run-time error 2114
saying that it can't use the image... 'blah-blah.jpg'. Now, I know
for a fact that I've done this with the same images before and they're
all JPEGs. Also, it gives that message for a different image
everytime. I have 574 images in total.

What could this issue be?

Cheers

Dean

Aug 8 '07 #3
Could it be that the graphics filters were, for some reason, not installed?
That's about all that comes immediately to mind.

If you have 574 images, you may well have to take a look at MVP Stephen
Lebans' http://www.lebans.com/printfailures.htm. PrintFailure.zi p is an
Access97 MDB containing a report that fails during the Access formatting
process prior to being spooled to the Printer Driver. This MDB also contains
code showing how to convert the contents of the Image control to a Bitmap
file prior to printing. This helps alleviate the "Out of Memory" error that
can popup when printing image intensive reports.

But, I can't remember trying a report with many pictures, not using that
technique, or files that already were bitmaps, since Access 97... the memory
leakage problem _could_ have been corrected. Stephen also has a freely
downloadable Control that might be of Help -- I haven't used it in a Report,
either, but I have a lot of confidence in Stephen's work.

Larry Linson
Microsoft Access MVP

"Dean" <de**********@y ahoo.comwrote in message
news:11******** **************@ i13g2000prf.goo glegroups.com.. .
Hi Larry,

Thanks for the reply! I got this working with your suggestion, BUT
(yes, you just knew this was coming...) I get a run-time error 2114
saying that it can't use the image... 'blah-blah.jpg'. Now, I know
for a fact that I've done this with the same images before and they're
all JPEGs. Also, it gives that message for a different image
everytime. I have 574 images in total.

Aug 8 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
5646
by: marwa mohamed | last post by:
salamo alikom hi all when i run report that includes image control linked to a field in the table that contains the image path(on the server)and the record source of the report contains over 30 records a messege shows saying: "Microsoft Access doesn't support the format of the file'file path\filename.jpg' or file is too large.Try converting the file to BMP or GIF format". I want to know which one is the problem (the size) or (the format...
3
1804
by: Chris Minchin | last post by:
Hi there, I am a bit of a newboy to access I have a database which I wish to have pictures. for example: record one will have data and a picture, record two will have different data and a diferent picture. I am pretty sure that a picture bound frame is used, but are unable to make it work. Anybody able to help? Chris
4
2508
by: Bernie Raffe | last post by:
When I change the 'cookieless' flag in the WebConfig file to true, everything works fine on my local PC, but the images fail to appear when using the remote server. I specify my images throughout using a relative directory structure, such as 'images/topbanner.jpg'. I tried changing this to ~/images/topbanner.jpg and .../images/topbanner.jpg, but this didn't work locally so I didn't even bother trying it out remotely. Tthe problem...
15
22316
by: Jameson | last post by:
Happy New Year, Everyone! I am trying to figure out how to display a bunch of images (mainly JPEGs, but possibly a few GIFs and PNGs as well) that are stored in a local directory on the system. I can do this with the glob() function, but I can't seem to put in a directory other than one within the webroot. For example, I can only put "/uploads" and not "/Volumes/jray/Pictures...". Any ideas how to get around this? If I can't use the...
1
3243
by: Xah Lee | last post by:
The following is a program to generate thumbnail images for a website. Useful, if you want to do that. It is used to generate the thumbnails for my “Banners, Damsels, and Mores” project gallery. ( http://xahlee.org/Periodic_dosage_dir/lanci/lanci.html ) Comments and versions in other lang welcome. Xah
1
1808
by: colmkav | last post by:
Hi, when I try to add a logo to my form I click on the unbounded object frame and then browse for tje location of my logo. I open the .bmp file but get an error claiming "OLE object isnt registered". I get same type of error for other items I try to upload. could someone pls tell me how I can resolve this problem?.
1
6938
by: BRAHM | last post by:
Hi, I am creating reports using the crystal reports available in VS 2005. I am not figuring out how to load dynamically images in a picture box (at runtime) inside of my reports. how could I do that ? Thanks,
3
4363
by: evenlater | last post by:
I have an Access application on a terminal server. Sometimes my users need to export reports to pdf, rtf or xls files and save them to their own client device hard drives. They can do that right now the way I have this set up, but it's confusing and slow. When they browse for a place to save the reports, they see all of the drives on the terminal server as well as their own client drives. So they're likely to want to choose "My...
5
13388
matheussousuke
by: matheussousuke | last post by:
Hello, I'm using tiny MCE plugin on my oscommerce and it is inserting my website URL when I use insert image function in the emails. The goal is: Make it send the email with the URL http://mghospedagem.com/images/controlpanel.jpg instead of http://mghospedagem.comhttp://mghospedagem.com/images/controlpanel.jpg As u see, there's the website URL before the image URL.
0
9704
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, well explore What is ONU, What Is Router, ONU & Routers main usage, and What is the difference between ONU and Router. Lets take a closer look ! Part I. Meaning of...
0
10562
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10319
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10303
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10070
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6845
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5508
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5639
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4282
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.