Image Placement Follow

0
Avatar
yona Tauber

I'm printing labels based on a database with defined fields.

I have about 10 images. Each image is identified by a number.

I want only images referenced in the DB to print.

However I want them to print one next to another and centered on my label.

Meaning: sometimes, I'll want image 2 & 5 to print. Sometimes images 1, 3, & 4. Sometimes 2 & 4 etc

 

When it comes to Text, I can have one 'Object' with various 'Data Sources' and set the conditions for each Data Source when to print. I can place and align the object on my label and whichever Data Sources meet the set condition will print within that set range.

Can something like that be done with images?

 

7 comments

0
Avatar
Pete Thane
Comment actions Permalink

Is there a maximum number of images that will be printed at any one time and how are the numbers stored in the database.

Is it something like

IMAGE1, IMAGE2, IMAGE3, IMAGE4.....etc

      Y,             N,           Y,              Y.....

 

Or 

1stPicture,,2ndPicture, 3rdPicture, 4thPicture etc.

      1,             3                 ,7 ,              10

0
Avatar
yona Tauber
Comment actions Permalink

Let's suppose there will be a maximum of 3 images in total.

 

The database looks as follows

"Images"

"1,3,7"

0
Avatar
Pete Thane
Comment actions Permalink

Okay.

I dont suppose there is any way to change it so the image numbers are in three separate fields in the database, as it would just make the logic simpler?

0
Avatar
yona Tauber
Comment actions Permalink

Not sure I understand what you're trying to say.

I might be able to change it to have the image numbers in separate fields. Would that help? If yes, how would I get the images to print the way I want?

If you can give me the solutions (where they exist) for each way - image numbers in separate fields / image numbers in same field.

0
Avatar
Pete Thane
Comment actions Permalink

There maybe different ways of achieving this but for the way I was thinking of with the image names/numbers in the same field you would need to create a complex Visual Basic routine first that strips out the (potentially) three numbers in to three different fields which you would need to Name for ease of referemce.. 

With the numbers separated you could then use conditional printing to control your printing process:

  • Create you label with a position for just one label
  • When complete, right click on the Template1 tab at the bottom and insert a new template and copy and paste your one label design on this and then edit Template2 to allow for two images
  • Repeat this process for the 3rd image
  • Once you have done that and linked the images to either the different database fields or Named Data Sources you would need to again right click on each TemplateX tab and go into the Properties of that template
  • From there lick on the Print When button (ringed in the image below) and set up some lines of conditionally print based on expression where the conditions would be something like

Single Image

Line1 - DatabaseField/NamedField image1 is greater than 0

LIne2 - DatabaseField/NamedField image2 is equal to 0

Line3 - DatabaseField/NamedField image1 is equal to 0

Two Image

Line1 - DatabaseField/NamedField image1 is greater than 0

LIne2 - DatabaseField/NamedField image2 is greater than 0

Line3 - DatabaseField/NamedField image1 is equal to 0

Three Image

Line1 - DatabaseField/NamedField image1 is greater than 0

LIne2 - DatabaseField/NamedField image2 is greater than 0

Line3 - DatabaseField/NamedField image1 is greater than 0

 

I hope this makes sense

 

0
Avatar
Pete Thane
Comment actions Permalink

Sorry didnt paste this in

0
Avatar
yona Tauber
Comment actions Permalink

Thanks for that!

Please sign in to leave a comment.