October 23, 201312 yr Please see the attached file... you can log in as a guest with full access privileges. This is a very tiny file. The table attached to the form can get very long. It would be nice if I could sort the records by Fiscal Year, Quarter, and then ID. The Fiscal Year and Quarter fields should not be null. I've tried applying field validation but... in doing so I found the portal resets the rows upon field validation. It's very confusing so to the enduser so I haven't applied validation in the past. I've removed the portal sort and the reset but still, after validation the portal jumps. Is there anyway to have my cake and eat it to? I'd like it if when the enduser first views the layout the portal is sorted by Fiscal Year, Quarter and ID... and then have the screen not reset again until the next time the layout is opened? I tried a lot of different things. I tried a script on layout open... nothings working for me. Any ideas? PortalRowJumpingAfterValidation.zip
October 23, 201312 yr after validation the portal jumps That's not exactly how it happens. Validation occurs when you try to commit the records - and by that time the portal has already been exited. Note that you can have several portal rows that do not pass validation. Try attaching an OnObjectExit script to the portal. This will trigger whenever you attempt to exit a portal row, and you can have the script check the fields and prevent the exit if necessary. Leave the field level validation in place to ensure data integrity in any case.
October 26, 201312 yr Author Thank you for your feedback. I didn't realize you could prevent the exit. What if they decide at that point that they don't want to create the record afterall... Is there a way to incorporate that choice in the validation? So [field name] requires a value or do something to cancel creation of this record?
October 29, 201312 yr Since you have a script running at that point, you can do practically anything you want. Keep in mind, though, that if they created more than one record in the portal without committing, reverting the record will cancel the creation of all those records (as well as any other uncommitted changes).
Create an account or sign in to comment