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

Not sure how Status(current portal row) works...


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

Recommended Posts

  • Newbies
Posted

I have 2 files. File A and B. File A has a portal row with related fields in fields B. I'm trying to set it up so that I can go from a field in a record in file B and want to go to that portal row in file A. I use a script button in the portal row to get from file A to File B where something happens and i'm trying to get back to the same spot where I executed the script (same portal row). I'm able to get back to the correct record in file A but want to be dropped off in the portal row field that I clicked on to execute the original script. I have not been able to get the status(current portal row)to work. I was trying to use a field as pointer where the current row# would be stored so that when I came back to File B could help me get back to the correct portal row.

Version: v6.x

Platform: Windows 2000

Posted

Hi -

You will need a global number field (gPortalRow) in file A

Then, in your script you add the line

Set Field [gPortalRow, " Status(CurrentPortalRow) "]

Add this before you perform your external script.

When coming back to File A you will need the following

Go To Field [ Your Portal Relationship::Filed x ]

where field x is a field that exists in that portal

Go To Portal Row [by field value, gPortalRow]

You have to target the portal first before you can go to a row in it. This is especially important if you have multiple portals on a single layout.

HTH

  • 2 weeks later...
  • Newbies
Posted

This makes sense but I am unable to get the "set Field..." part to work. I pause my script after that step and see that it has 0.00 in the global field. I had the cursor in the portal row that I wanted.

Posted

Setting gPortalRow must be the very first step in your script that's executed by your portal button, because as soon as the focus leaves the portal, the current portal row becomes undefined.

Also, make sure that you haven't inadvertently defined your global field gPortalRow as a regular number field. I do it all the time.

  • 2 months later...
Posted

I'm having a similar problem. I want to create a script that will duplicate a particular portal row. Before doing that however, as a test I created a calculation field in the parent file in which the calculation is simply "Status (CurrentPortalRow)", and the calculation is unstored. I put the field on the layout with the portal (the only portal on the layout), and tried selecting various rows in the portal, both by highlighting the entire portal row, and by placing the cursor into one of the editable fields in the row.

No matter what I do, the CurrentPortalRow calc field always displays "0". That is, it doesn't seem to know that I am in a portal row. Both the portal and the calc field are in the body of a layout that is displayed in form view.

Posted

I don't think Status(CurrentPortalRow) works as a calculation field in FM 6 and below, only in a scripted calculation.

Posted

Queue is right, Status(CurrentPortalRow) doesn't work as a calculation field on its own. You should use a script with SetField("SomeGlobalField", "Status(CurrentPortalRow)"), as Andy and Bob explained above.

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