Prev: não acho meu orkut
Next: maike yordano pirela vera
From: Armen Stein on 21 Jan 2010 15:02 On 21 Jan 2010 18:59:52 GMT, "David W. Fenton" <XXXusenet(a)dfenton.com.invalid> wrote: >I was badly burned by an unheralded aspect of the bookmark bug, >i.e., that setting the bookmark to move the record pointer >implicitly saves any edits to the departed record, but errors in >that save were getting eaten by Access. Thus, this code was >dangerous: > > With Me.RecordsetClone > .FindFirst "[PK]=" & Me!cmbComboBox > If Not .NoMatch Then > Me.Bookmark = .Bookmark > End If > End With Okay, I see your point in this case. I don't think we've ever used Bookmark navigation on an editable record - we use it a lot on read-only continuous forms, where this bug wouldn't occur. Armen Stein Microsoft Access MVP www.JStreetTech.com
From: Paul on 22 Jan 2010 03:07 My thanks to all the luminaries who contributed to this conversation, for their help and suggestions. Some of the more advanced topics discussed were over my head, but you've given me some great ideas for eliminating the write conflicts I had originally asked about. And thanks again for that handy navigation bar, John. Paul
From: David W. Fenton on 22 Jan 2010 17:02
Armen Stein <ArmenStein(a)removethisgmail.com> wrote in news:1jchl55lfas63h99haj5qup7o79f7ot6ah(a)4ax.com: > On 21 Jan 2010 18:59:52 GMT, "David W. Fenton" ><XXXusenet(a)dfenton.com.invalid> wrote: > >>I was badly burned by an unheralded aspect of the bookmark bug, >>i.e., that setting the bookmark to move the record pointer >>implicitly saves any edits to the departed record, but errors in >>that save were getting eaten by Access. Thus, this code was >>dangerous: >> >> With Me.RecordsetClone >> .FindFirst "[PK]=" & Me!cmbComboBox >> If Not .NoMatch Then >> Me.Bookmark = .Bookmark >> End If >> End With > > Okay, I see your point in this case. I don't think we've ever > used Bookmark navigation on an editable record - we use it a lot > on read-only continuous forms, where this bug wouldn't occur. But I was only using it as a clear case of where you really *must* force the save explicitly. I believe that navigating out of a subform is another such situation where you should explicitly save, rather than depending on the implicit save occuring without problems (or bugs!). -- David W. Fenton http://www.dfenton.com/ usenet at dfenton dot com http://www.dfenton.com/DFA/ |