Solved

Insert image dependant on a variable field into Crystal Reports

Posted on 2013-12-11
4
543 Views
Last Modified: 2013-12-12
Hello Experts,
I would like to insert an image into a report and need some help. The report I am generating is a receipt. The stock database contains the text info I need for a particular item to output into the receipt but the images are stored in a separate folder.

My report contains a field called {part_code}. The images are located in C:\Images and are called {part_code}.jpg. For the receipt which contains {part_code} I would like to print on the recipt the image {part_code}.jpg.

It sounds like it should be easy, but I can't figure it out!
0
Comment
Question by:holdsworthbros
4 Comments
 
LVL 34

Assisted Solution

by:James0628
James0628 earned 125 total points
ID: 39713720
Which version of CR?  I think they added a capability like that at some point, but I'm not sure which version.  I don't see it in CR 10.

 James
0
 
LVL 22

Assisted Solution

by:Ido Millet
Ido Millet earned 125 total points
ID: 39713836
If memory serves, this started with Crystal XI. Insert a dummy picture into the report, but then right-click the picture, Format Graphic and under the Picture Tab you will find a "Graphic Location" option where you can enter an expression to control the path to the picture.
0
 
LVL 26

Accepted Solution

by:
Kurt Reinhardt earned 125 total points
ID: 39713892
FYI, if you only have a handful of part numbers then the Dynamic Graphic option (assuming you have a version that supports it) is feasible.  If you have hundreds of parts or more, then this isn't feasible and you'll run into problems.

If you have a large number of part numbers then I would suggest you store the images in a table and relate them to the part number.  This would be best practices.
0
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 125 total points
ID: 39714203
The above is accurate.  For CR10 and before the image had to be in the database and inserted as a field.

For CR XI (v11) and later (CR2008, CR2011) you can use the graphic formatting option.

mlmcc
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Hello everyone, Hope you find this as helpful as we did. We have on the company I work for an application built in Delphi V with Crystal Reports 8. We all know that Crystal & Delphi can be temperamental sometimes and the worst thing is, nearly…
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now