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

Conditional Portals


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

Recommended Posts

Posted

Hi,

I'm using filemaker 8.5 and I'm trying to get a layout that displays one of two portals conditionally.

I'm working on a database for the lab that I work in. To do an experiment you can use either of two different mixtures. The layout that I'm working on is an overview of what was done. What samples were used, conditions, and the components of the mix used.

So I made two portals to the two tables that store the two different mixture compositions. I stacked the two portals on top of each other. Is there a way to conditionally tell the layout to display this portal in front of this portal? And how would you set up the script to decide which layout to display?

Any help would be greatly appreciated.

thanks, js22

Posted

If you are scripting it then why not have 2 layouts, each featuring the different portal, but otherwise identical.

Switch layouts on demand in your script.

Posted

Hi js22:

I stacked the two portals on top of each other.

That will probably produce some less-than-desired effects.

Is there a way to conditionally tell the layout to display this portal in front of this portal? And how would you set up the script to decide which layout to display?

IdealData's suggestion of separate layouts would work. Alternatively, have you had a chance to use or experiment with Tab Control panels? They may be just the ticket for this situation, and FM8.5 introduced the Go to Object script step.

Posted

Thanks for the input. I can see how I could solve this with two layouts but I don't want to use two layouts for this overview.

I want to be able to scroll through records one after the other. If I do two different layouts then the mixture calculations would be blank for record X on the first layout but on the second layout it would have calculations for record X.

What I'm looking for is one layout that always has the mixture calculations displayed independent of whether they used mix1 or mix2 to do the experiment.

I can see the possible negative side effects of stacking two portals on top of each other. If anyone has any ideas to simplify this let me know. I'm just doing guess and check work now to see if this is possible.

thanks

js22

Posted

Unfortunately, since the data comes from two different tables, you won't be able to mix them together. However, if you can merge the two tables and differentiate the records using a field to categorize them as mix1 and mix2, you could use a filtered portal to display mix1 or mix2 depending on what value you had in the key field for the portal. Attached to this post is a simple example of a filtered portal to get you started.

CATEGORYv7.fp7.zip

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