Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

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

Recommended Posts

Posted

I wish all functions could take computed text arguments like GetField does.

Is there anyway to be able to *compute* or *lookup* the name of a layout to go to?

Is there anyway to be able to *compute* or *lookup* the name of a script to perform?

Is there anyway to be able to *compute* or *lookup* the name of an external file in which to perform a script?

For example, for each file I add to my system, I must add a new Preview layout to my floating Preview panel file and 8 new scripts. The layouts are identical except they call the corresponding scripts. The scripts are identical, except they reference the corresponding layout and the corresponding external file. And this duplication and renaming is all the more annoying due to the lack of cut n paste. But that'll be nothing compared to the hell when I find a bug in the Preview scripts and have to change it in 20 identical spots.

I'm pretty sure the answer is "no, you have to do it the hard way", but thought I'd check.

There's definitely some things about FMP that are NOT good!

Posted

1) You can go to a layout by number or you can create a looping script that goes to the next layout and tests Status(CurrentLayoutName) against a global field setting then exits.

2) No. With just FM, you must do a series of tests:

If(Condition1)

Perform Script(Script1)

End If

If (Condition2)

Perform Script(Script2)

End If

...

3) Same as 2).

-bd

Posted

Here is a formula which will 'compute' layout number from layout name:

PatternCount(Middle(LayoutNames(Status(CurrentFileName)), 1, Position(LayoutNames(Status(CurrentFileName)), gLayoutName, 1, 1)), "

This topic is 8064 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.