Expand my Community achievements bar.

Is it possible to build a "click to enlarge" option for images with Livecycle Designer?

Avatar

Level 1

Hello! I have built an audit form where the auditors report conditions and add photos by using an image field that when clicked, gives them a dialog box to choose a picture. The photos initially just load as a small image on the screen - a little bigger than a thumbnail and just large enough so you can see what they're talking about. However, I'd like to add an option that would allow the reader to click (or do something) which would enlarge or zoom the image, and then return to its initial smaller size.

I don't even know if it's possible and all my searching and reading hasn't come up with any solutions.  The best I can come up with as an alternative is to build some pages at the end of the audit report called "Photo Gallery" and use the global data option to sort of feed in whatever pictures are added into a larger image place on those gallery pages.  Not exactly what I was looking for, but at least it's a step in the right direction.

Thanks for any ideas you might send my way!

Jan

2 Replies

Avatar

Level 10

Hi Jan,

You could try having a custom dialog with a larger version of the image and then open the dialog when they click a button that covers the image on the form.

Here is an example. https://sites.google.com/site/livecycledesignercookbooks/home/ClickToEnlarge.pdf?attredirects=0&d=1

The dialog code used in the example was generated using the method described here ... Adobe LiveCycle Designer Cookbooks by BR001: Using app.execDialog() in an Adobe Designer Form

If your pictures are big then you will need another way of storing the image data, which is currently just a big JavaScript string literal, you'll see what I mean in the example.

Regards

Bruce

Avatar

Level 1

Thank you so much!  That has got some great potential!  I know right now, the picture is initially added with an image field, so the auditor clicks to add the picture.  I'm sure there's a different trigger that could be used for either operation (add pic or enlarge pic), like "click to enlarge' and "right-click to add the picture" or something along those lines.

Holy crap, I'm very excited about this!  Thank you again!  

Jan