Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×
The Claris Museum: The Vault of FileMaker Antiquities at Claris Engage 2025! ×

This topic is 5362 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

Hi everybody,

I am new to Filemaker and currently struggling to set up a calculation field to display photo based on the photo link from another field.

The database I am working on containing over 100,000 jpegs and each record has a photo as proof of service. Manually importing those photos would take several month to complete. I have 2 photo fields:

Field A contain the link or path to the location of a photo stored on my hard disk. This information is imported from Excel data spreadsheet.

Field B is set to display the photo according to the link from field A.

Example from the field A :C:photosMay2010IMG_2121.jpg

Working out the calculation for field B to display the photo from field A is beyond my current ability.

I hope some experts in this forum can help me to work out the needed calculation for field B so all photos can be displayed once the data from field A are imported.

I am using FM Pro Advanced 11 on Win XP.

Thanks in advance

Posted

Field_B should be defined as a container field type to hold the image contents, if it is not already defined as such.

A script will likely be needed to achieve this. Script should loop through all records and insert the image into the container field. A local variable can be used to store the path, which will need to be prefixed with "image:/ e.g. "image:/C:/red_flowers.jpg".

Container data can either be stored as a reference (where it is fetched from the local hard drive) or in the actual Filemaker database, where it can tend to take up a lot of space. I prefer reference storage, but its downside is that if file is deleted from hard drive or in wrong folder, image won't appear. Also when DB is copied to another computer, image folder must be copied also, if reference storage is used.

The second option is to use a webviewer to view the data. An example is attached. It assumes the flower images are present in C: root.

Photo_Example.zip

Posted

Try making Field B a Calculation field (result type is Container) =


"imagewin:/" & Substitute ( Field A ; "" ; "/" )

Manually importing those photos would take several month to complete.

You could import them all at once:

file:///Applications/FileMaker%20Pro%2011%20Advanced/FileMaker%20Pro%20Advanced.app/Contents/Resources/English.lproj/FileMaker%20Pro%20Help/html/import_export.16.16.html#1044791

But using a calculated path is probably better in your situation. If you ever move the images, you can change the calculation to follow.

  • Newbies
Posted

Thanks for both solutions and I will give them a go to see if the problem can be resolved. Really appreciate any help from your guys.

This topic is 5362 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.