Jump to content

PHS

Newbies
  • Posts

    3
  • Joined

  • Last visited

Everything posted by PHS

  1. I have encountered a problem that I can't explain or work around.  I am using FileMaker Pro Advanced 13.  I have a global field on a table (glbClients). I also have a value list (Client Code and Name) that displays the Client Code as the first field and the Client name as the second field.  I have a layout based on the Client table. On this layout, I am displaying the glbClients Field with a Popup Menu that uses the "Client Code and Name" popup menu.  There is a On Modify script trigger on the glbClient field that runs a script that finds the appropriate client code.  The problem: The Global field with the Popup Menu is not always displaying correctly. Sometimes (not always), it is also showing party of the Client Name (the second field in the value list). The value being stored in the glbClients field is correct and the trigger is working properly. This is only happening on the glbClients field that has the Popup Menu on it. I placed the glbClients field on the same layout as an edit box and it is displaying correctly.  I have attached a snapshot of what I am seeing.    Â
  2. I am struggling with the same issue. To make it even a bit tougher on my users, the field uses a value list and the validation is against the same Value List. So, the user is making a mistake on say the 3rd row of the portal, sent back to the first row, the value list drops down, and they are unable to click on the 3rd row to fix their mistake. Did you find a solution to this issue? Any help is much appreciated.
  3. Coming from the SQL world, it was frustrating to not have the ability to enforce uniqueness on more than one field. After searching many posts, I came up with a modified version of what was proposed in this post. 1. Create a calculated field concatenating the fields to be checked. UniqueField = field 1 & field2 2. Setup the self join on the calculated field. 3. Create another field PKCounter = Count ( UNIQUE_Table::__pkID ) 4. Create an Object Name for the last field that is part of the concatenated field that will be inputted into on the layout. ObjectNameField2 = ONField2 5. Create an Object Name for the next field to be entered after field2. ObjectNameNxtField = ONNxtField 6. Create a script similar to the one in Done.pdf above, but instead does the following: Commit Records/Requests[ No dialog ] If [ STATIC_Table::PKCounter > 1 ] Show Custom Dialog [ Title: "Unique Check Failed"; Message: "The combination of field1 and field2 must be Unique. Choose Revert to change the record or Delete to delete it."; Buttons: “Revert”, “Delete” ] If [ Get (LastMessageChoice) = 2 ] Delete Record/Request Else Go to Object [ Object Name: "ONField2" ] End If Else Go to Object [ Object Name: "ONNxtField" ] End If Exit Script [ Result: 0 ] 6. On the layout to be used for data input, go to the field2 and put an OnExit Trigger to perform the script. You do need to take into account any required fields in the table and when they are validated, since the commit will throw validation errors if those other fields are not filled in. That is the reason for the other object named field. It is a required field, but only validated when the user modifies it. When it is set to always validate, you will get an error on the initial commit.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.