I have a set of criteria that I am evaluating prior to opening an Update Form. The criteria are being correctly evaluated, but I am at a loss for figuring out how to get the Update Form from being opened.
The criteria are in the "Browse Box Before Insert/Update a Record From Browse Box on Sessions" embed point.
It might be easier to put the logic in the form and exit before it goes too far.
I’d use window.init after opening files, assuming your criteria uses file info, and return level:Cancel if it fails.
edit:
Oops Legacy. Not sure of the embed, but you should get the idea
A potential problem with that is that it will add a record to the database on insert, which might not be desirable.
I don’t remember anything about legacy templates, but it might be worth looking at the browse code in the embeditor and looking for place(s) where the update form is called, then find an appropriate embed point to intercede.
Oh yes, the topspeed file autoinc is different from sql, so Ask might not be the appropriate method. However, for a browse on an sql view it might be desirable to evaluate the update criteria as late as possible.