Jump to content

Conditional Container Contents


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

Recommended Posts

I am new to this forum, and have been digging deep into FM for over a year (v 4-8) now.

I'm using 8 (&7) on WinXPpro to generate calculated containers to show multiple images for an individual object. That works fine, as long as the actual image file is named the same as what I predetermine. The plan is to not have to insert up to 1000's of images.

My problem: I want to add a flag in the container calc to display a placeholder "Unavailable" image if the file referenced is not there. Instead of showing the text "The file cannot be found:path", another image would show up, indicating missing image.

Hope this is clear, and hope someone can help. I've tried almost every Logical Function in the Field Definition possible.

Thanks, Sean

Link to comment
Share on other sites

So, what I ended up doing with this, is to just add a flag field for each image field, which is set up as a check-box. If the box is checked, a placeholder image is displayed; unchecked, the standard image is displayed, unless, of course it is not there. Unfortunately, it is a manual solution, but seems to be the only work around, besides scripting things.

Thanks for reading, and thinking.

Link to comment
Share on other sites

The Troi File plug-in has a file length test which, if used in an unstored calculation, can tell you if the referenced file is there or not. It produces a known error if it's not, which you can do a (slow) Find for.

There are other plug-ins that can do this also I imagine. There would be command line tests on either platform (can't say for Windows), but those would require scipting.

Link to comment
Share on other sites

This topic is 5692 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
 Share

×
×
  • Create New...

Important Information

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