Subject Re: [IBO] Stay on newly inserted record
Author Paul Vinkenoog
Hi Salvatore,

> It doesn't do the trick. I have seen in the object inspector that
> there is another option not mentioned in the help file,
> raKeepDataPosOrRowNum, but also this option doesn't do the trick.

I don't have that option (IBO 4.2 If_TEST), so I suppose you've got a
newer version. The name suggests that this option will try to find the
same data record and, failing that, positions on the same row number.
(raKeepDataPos positions on the first row if the record isn't found.)

If IBO can't find the record back, the first thing that comes to mind
is: are the KeyLinks set up correctly? Or do you have a trigger that
assigns/modifies a PK field on the server?

> I have to stay on the newly inserted record because before closing
> this dialog I have to retrieve the value of a field that has to be
> passed to another dialog. To resolve I retrieve this value before
> posting the row, in the BeforePost handler. But I'd like to retrieve
> it when the row has been successfully committed

Posted or committed? Can't you use the AfterPost event?


Greetings,
Paul Vinkenoog