Subject Re: Problem with TIB_LookupCombo in TIB_Grid
Author mmenaz
I've noticed this problem and sent a patch to Jason, but I don't know
if he had the time to try it and include the fix in the next subrelease.
In the meantime, you could set ClearSelectionOnExit to false, that
seems not to bring out the problem.
Here follows the patch, so you can help us test it (IB_Grid.pas)
(added the try...except code)

if ClearSelectionOnExit then
ClearSelection( False );
on EAbort do
I don't know is there is a better way for "trapping into nothing" a
silent exception, hope you do :)
Marco Menardi

--- In IBObjects@y..., "slsolutions2002" <strtline@a...> wrote:
> I have a TIB_LookupCombo in a TIB_Grid. All works fine: I can enter
> data into the grid and use the TIB_LookupCombo to populate the grid
> column to which it is linked. In the forms FormShow Event I open
> both querys: The query for the TIB_Grid and the query for the
> TIB_LookupCombo. In the forms FormClose Event I close both querys.
> Here is the problem: If focus is set to any column in the grid,
> except the column linked to the TIB_LookupCombo, and the user clicks
> the forms close icon, the form closed without incident. However, if
> focus is set to the TIB_Grid column that is linked to the
> TIB_LookupCombo and the forms close icon is clicked, I get the error
> message "Cannot focus a disabled or invisible window". This error
> occurs when the query is closed. Can anyone help ? Thanks.