Form Select with Automatic Lookup - Not saving

I was using several forms that had a ‘manual lookup’ select field - where I typed in the values I wanted - all the forms used the same select data so it was painful when the customer wanted to change the drop down options - I had to go edit each form again. So I decided to create a table, and have the select pull from the table instead. That way it’s much easier to edit the contents of the select field in one place and all the forms would automatically pull the new data.

I edited my first ‘data entry’ form with an ‘automatic lookup’ select field that pulls options from another table. That is working fine and redirects to a grid after the insert. I have almost the identical form for ‘editing’ a record, which is where I’m having problems. When the form loads the existing record, the new Automatic Lookup Select field is just showing the default select order, rather than the value that already existed - so if someone isn’t paying attention, that select field will just be changed to the first option every time. I tested it, and after saving, it redirects to the grid but changes the Select field to the default.

I read that you can set the Title and value - which I have working with Session Variables. On the form ‘load’, I’m grabbing the name and value of the existing record, and using that as the title - which ‘seems’ to work perfectly.

However if I edit anything in the form and save it, the new data is not saved. In fact, after saving the form, it is supposed to redirect to a grid (works perfectly with adding a record, just editing is the issue) - but when I save the form now, it just sits there and never redirects. I should add that if I click on the drop down and select another option in the Select field, the form saves that value and redirects as expected. It’s just when I leave the Title name and Title Values alone - nothing is updated and no redirection occurs.

I can’t fathom what would be causing the issue here. If anyone has any suggestions, it would be greatly appreciated!

Thanks in advance!

Mark.

UPDATE: It seems using the Title approach, we can’t use a variable for the Title Internal Value. So I set the Title Name as the Name variable I set on load, and the Title Internal Value to be -1. Then on the ‘Before Update’ event, query the field and if it == -1, then I set the field to the Value variable I generated on load. Seems a long way around, but it’s working now.

apparently it is just a select field configuration problem, try:
review the Create Select
check the connection to the database of the select field
check if your int or text fields

some time ago that happened to me, and the problem was solved like this I’m new in this.

Thanks Claudio,

I echoed the variable in the header which displayed what I expected, and the select was pulling from a ‘double’ type field - so I’d have thought the variable would be the proper format. I guess I could try formatting the variable as a double, just to ensure it’s formatted correctly. I’ll give it a try!

I do have it working by setting the default title as -1 and then checking its value after update and updating to the original variable if it == -1

Thanks so much for the suggestion!