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

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

Recommended Posts

Posted

I am trying to create a script that will go to the next row of a portal (thus creating a new, related record) and enter data there. For some reason, no matter what portal commands I use, I cannot get past the last row that already has data in it. 

 

Any advice on how to create this new record in the portal through a script would be appreciated.

 

Thank you.

Posted

For some reason, no matter what portal commands I use, I cannot get past the last row that already has data in it.

 

In the relationship the portal is based on, the option to "allow creation of related records via this relationship" must be checked for the portal TO; otherwise you'll not be able to create a related record in the portal, manually or per script, because you'll only see existing records. 

 

Activate that option, and give the portal an object name in the Inspector palette. Once these prerequisites are in place, you can simply script …

Go to Object [ objectNameOfPortal ]
Go to Portal Row [last ]
Set Field [ portalTO::someField ; "someValue" ]

… because the last portal row in a portal whose relationship allows creation is the “spare row” used to create new related records.

Posted

Thank you for the ideas. I had the relationship set up correctly, but it was still stopping at the first row and changing the data there. I just set up an "If empty" on one of the fields in the row, and instructed it to perform the script, but if not go to the last row, and it seems to be working.

 

Thank you.

Posted

Here is a technique that you might like better than the "go to last portal row" method. (see the attached sample).

 

I started using this technique for all of my data entry into portals and my users seem to prefer it over the "go to last portal row" method. Especially if there are a lot of line items in the portal, as this method eliminates the need for scrolling.

new_portal_record_with_portal_filtering.zip

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