Jump to content

Portal - Scripting Problem


flyzone

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

Recommended Posts

Recently I built a DB using the FileMaker Business Tracker solution as a template. (I'm just at the beginning) but I can't solve a problem using a script on a portal.

This is the situation. On the "Company" layout I have a portal from the "Contact" table that display the name of people working for the company. My intention is to click on the contact name on the portal in order to get more details (phone, mail, email etc).

To do this I imported the script from the FM Business Tracker file and adapted it to my settings.

The Script works fine. The Contact Details windows open but the record displayed is always the first one from the contact list. I'm sure that some parameters are wrong but I can't figure out what due to my inexperience.

Hope someone can give me some suggestions.

Thanks,

Fly

cool.gif

Link to comment
Share on other sites

Make sure Go to Related Record [show only related, "yourrelationship] is the first step in your script before Commit Record or any other steps that take focus away from the portal.

Link to comment
Share on other sites

Thanks for your reply.

I tried to build a simple script using the Go to Related Record [show only related, "yourrelationship] but in this case the record that the new windows is showing is always the first one on the portal. So if I click on the third name the info for the first name on the portal will show up.

Fly

Link to comment
Share on other sites

As I said, GTRR needs to be the first step. You're opening a new window first, so you lose your place on the Company layout and the first related record becomes the default. Instead, use the New window option in the GTRR step.

Link to comment
Share on other sites

It looks pretty good to me. I would suggest doing away with the Insert and Clear steps and using Set Field instead though.

Insert Current Date [Companies::Notes]

Insert Text [Companies::Notes; " - "]

Insert Current Time [Companies::Notes]

can be changed to

Set Field [Companies::Notes; Companies::Notes & Case( not IsEmpty(Companies::Notes);

Link to comment
Share on other sites

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